Fix order of types for relationship use case options

This commit is contained in:
Karina Kwiatek 2022-01-23 01:01:32 +01:00 committed by Karina Kwiatek
parent 3b1287c424
commit b74c64c664
2 changed files with 4 additions and 4 deletions

View File

@ -6,8 +6,8 @@ require "errors"
module UseCase
module Relationship
class Create < UseCase::Base
option :source_user, type: Types::Coercible::String | Types.Instance(User)
option :target_user, type: Types::Coercible::String | Types.Instance(User)
option :source_user, type: Types.Instance(::User) | Types::Coercible::String
option :target_user, type: Types.Instance(::User) | Types::Coercible::String
option :type, type: Types::RelationshipTypes
def call

View File

@ -6,8 +6,8 @@ require "errors"
module UseCase
module Relationship
class Destroy < UseCase::Base
option :source_user, type: Types::Coercible::String | Types.Instance(User)
option :target_user, type: Types::Coercible::String | Types.Instance(User)
option :source_user, type: Types.Instance(::User) | Types::Coercible::String
option :target_user, type: Types.Instance(::User) | Types::Coercible::String
option :type, type: Types::RelationshipTypes
def call