Skip to content

Commit

Permalink
set the instance variables with a pre @
Browse files Browse the repository at this point in the history
  • Loading branch information
hallgren committed Mar 18, 2015
1 parent 9e2f113 commit d568865
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/sandthorn/aggregate_builder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def build_from_events(events)
end
end
aggregate.send :clear_aggregate_events
aggregate.send :load_aggregate_stored_instance_variables
#aggregate.send :load_aggregate_stored_instance_variables
return aggregate
end

Expand Down Expand Up @@ -75,7 +75,7 @@ def set_aggregate_versions(aggregate, aggregate_version)

def set_aggregate_deltas(aggregate, attribute_deltas)
attribute_deltas.each do |delta|
aggregate.instance_variable_set delta[:attribute_name], delta[:new_value]
aggregate.instance_variable_set "@#{delta[:attribute_name]}", delta[:new_value]
end
end

Expand Down

0 comments on commit d568865

Please sign in to comment.