Permalink
Browse files

Merge remote-tracking branch 'caius/master'

  • Loading branch information...
2 parents e6a7efd + b6f8c62 commit f99341582cb26817e65de418fcf2b7f9ebac0053 Emmanuel Oga committed Aug 8, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/firering/data/room.rb
@@ -7,6 +7,7 @@ class Room
alias_method :locked?, :locked
alias_method :full?, :full
alias_method :open_to_guests?, :open_to_guests
+ alias_method :to_s, :name
def stream(&callback)
join { |data, http| connection.stream(self, &callback) }
@@ -91,7 +92,7 @@ def unlock(&callback)
# :type => "TextMessage", :body => "Hello"
def speak(data, &callback)
connection.http(:post, "/room/#{id}/speak.json", "message" => data) do |data, http| # Response Status: 201 Created
- callback.call(Firering::Message.instantiate(connection, data, "message"))
+ callback.call(Firering::Message.instantiate(connection, data, "message")) if callback
end
end

0 comments on commit f993415

Please sign in to comment.