Module: ActivePubsub::PublishWithSerializer
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/active_pubsub/publish_with_serializer.rb
Defined Under Namespace
Modules: ClassMethods
Instance Method Summary collapse
Instance Method Details
#serialized_resource ⇒ Object
11 12 13 14 15 |
# File 'lib/active_pubsub/publish_with_serializer.rb', line 11 def serialized_resource serialized_resource_attributes.merge!(:changes => previous_changes) if previous_changes ::Marshal.dump(serialized_resource_attributes) end |
#serialized_resource_attributes ⇒ Object
17 18 19 20 21 22 |
# File 'lib/active_pubsub/publish_with_serializer.rb', line 17 def serialized_resource_attributes @serialized_resource_attributes ||= self.class .publish_serializer.new(self) .attributes .symbolize_keys! end |