Permalink
Browse files

Merge pull request #215 from jaymiejones86/issue-213-documentation

Update Interactor documentation to not use Repository#persist
  • Loading branch information...
TiteiKo committed Jun 16, 2017
2 parents d3a861b + 7593c79 commit ad573dce93a332e2ecb5a8d097fe83170a2b1073
Showing with 3 additions and 6 deletions.
  1. +3 −6 lib/hanami/interactor.rb
@@ -205,12 +205,11 @@ def initialize(*args)
#
# def initialize(params)
# @params = params
# @user = User.new(@params)
# @foo = 'bar'
# end
#
# def call
# @user = UserRepository.new.persist(@user)
# @user = UserRepository.new.create(@params)
# end
# end
#
@@ -231,12 +230,11 @@ def initialize(*args)
#
# def initialize(params)
# @params = params
# @user = User.new(@params)
# end
#
# # THIS WON'T BE INVOKED BECAUSE #valid? WILL RETURN false
# def call
# @user = UserRepository.new.persist(@user)
# @user = UserRepository.new.create(@params)
# end
#
# private
@@ -292,7 +290,6 @@ def valid?
#
# def initialize(params)
# @params = params
# @email_test = EmailTest.new(@params)
# end
#
# def call
@@ -302,7 +299,7 @@ def valid?
#
# private
# def persist_email_test!
# @email_test = EmailTestRepository.new.persist(@email_test)
# @email_test = EmailTestRepository.new.create(@params)
# end
#
# # IF THIS RAISES AN EXCEPTION WE FORCE A FAILURE

0 comments on commit ad573dc

Please sign in to comment.