lib/blather/client/dsl.rb in blather-0.4.4 vs lib/blather/client/dsl.rb in blather-0.4.5

- old
+ new

@@ -17,11 +17,11 @@ ## # Push data to the stream # This works such that it can be chained: # self << stanza1 << stanza2 << "raw data" def <<(stanza) - write stanza + client.write stanza self end ## # Prepare server settings @@ -81,11 +81,11 @@ end ## # Write data to the stream # Anything that resonds to #to_s can be paseed to the stream - def write(stanza) + def write_to_stream(stanza) client.write stanza end ## # Helper method to make sending basic messages easier @@ -120,10 +120,10 @@ stanza = Blather::Stanza.class_from_registration(:query, "http://jabber.org/protocol/disco##{what}").new stanza.to = who stanza.node = where client.register_tmp_handler stanza.id, &callback - write stanza + client.write stanza end ## # Checks to see if the method is part of the handlers list. # If so it creates a handler, otherwise it'll pass it back