Class: Pressy::Action::Pull
- Inherits:
-
Object
- Object
- Pressy::Action::Pull
- Defined in:
- lib/pressy/action/pull.rb
Defined Under Namespace
Classes: LocalPost
Instance Attribute Summary collapse
-
#server_posts ⇒ Object
readonly
Returns the value of attribute server_posts.
Instance Method Summary collapse
- #changeset ⇒ Object
- #has_changes? ⇒ Boolean
-
#initialize(params) ⇒ Pull
constructor
A new instance of Pull.
Constructor Details
#initialize(params) ⇒ Pull
Returns a new instance of Pull
6 7 8 9 |
# File 'lib/pressy/action/pull.rb', line 6 def initialize(params) @local_posts = params.fetch(:local) @server_posts = params.fetch(:server) end |
Instance Attribute Details
#server_posts ⇒ Object (readonly)
Returns the value of attribute server_posts
4 5 6 |
# File 'lib/pressy/action/pull.rb', line 4 def server_posts @server_posts end |
Instance Method Details
#changeset ⇒ Object
15 16 17 |
# File 'lib/pressy/action/pull.rb', line 15 def changeset @changeset ||= build_changeset end |
#has_changes? ⇒ Boolean
11 12 13 |
# File 'lib/pressy/action/pull.rb', line 11 def has_changes? changeset.has_changes? end |