Module: Diaspora::Webhooks

Included in:
Comment, Conversation, OstatusBuilder, Like, Message, Post, Profile, RelayableRetraction, Request, Retraction
Defined in:
lib/diaspora/webhooks.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) receive(user, person)



23
24
25
# File 'lib/diaspora/webhooks.rb', line 23

def receive(user, person)
  raise 'you must override receive in order to enable federation on this model'
end

- (Object) subscribers(user)



19
20
21
# File 'lib/diaspora/webhooks.rb', line 19

def subscribers(user)
  raise 'you must override subscribers in order to enable federation on this model'
end

- (Object) to_diaspora_xml



9
10
11
12
13
# File 'lib/diaspora/webhooks.rb', line 9

def to_diaspora_xml
  xml = "<XML>"
  xml += "<post>#{to_xml.to_s}</post>"
  xml += "</XML>"
end

- (Object) x(input)



15
16
17
# File 'lib/diaspora/webhooks.rb', line 15

def x(input)
  input.to_s.to_xs
end