lib/vedeu/repositories/model.rb in vedeu-0.7.2 vs lib/vedeu/repositories/model.rb in vedeu-0.7.3

- old
+ new

@@ -106,15 +106,11 @@ # @note If a block is given, store the model, return the model # after yielding. # @todo Perhaps some validation could be added here? # @return [void] The model instance stored in the repository. - def store - new_model = repository.store(self) - - yield if block_given? - - new_model + def store(&block) + repository.store(self, &block) end end # Model end # Repositories