Module: Messaging::Message::Follow
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.call(source, receiver = nil, copy: nil, include: nil, exclude: nil, strict: nil) ⇒ Object
6 7 8 |
# File 'lib/messaging/message/follow.rb', line 6 def self.call(source, receiver=nil, copy: nil, include: nil, exclude: nil, strict: nil) follow(source, receiver, copy: copy, include: include, exclude: exclude, strict: strict) end |
Instance Method Details
#follow(source, receiver = nil, copy: nil, include: nil, exclude: nil, strict: nil) ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/messaging/message/follow.rb', line 10 def follow(source, receiver=nil, copy: nil, include: nil, exclude: nil, strict: nil) if receiver.nil? receiver = self end if receiver.class == Class receiver = receiver.build end Copy.(source, receiver, copy: copy, include: include, exclude: exclude, strict: strict, metadata: false) receiver..follow(source.) receiver end |