lib/osso/graphql/mutations/create_enterprise_account.rb in osso-0.0.3.16 vs lib/osso/graphql/mutations/create_enterprise_account.rb in osso-0.0.3.17

- old
+ new

@@ -6,15 +6,17 @@ class CreateEnterpriseAccount < BaseMutation null false argument :domain, String, required: true argument :name, String, required: true + argument :oauth_client_id, ID, required: false field :enterprise_account, Types::EnterpriseAccount, null: false field :errors, [String], null: false def resolve(**args) enterprise_account = Osso::Models::EnterpriseAccount.new(args) + enterprise_account.oauth_client_id ||= context[:oauth_client_id] return response_data(enterprise_account: enterprise_account) if enterprise_account.save response_error(errors: enterprise_account.errors.full_messages) end