src code

instance method IRC#topic

IRC#topic(channel, topic) → self
IRC#topic(channel, hollaback) → self
  • channel (String) – Channel to set/get topic
  • topic (String) – Topic to set
  • hollaback (Function) – Callback to receive the channel topic. The first argument is the channel, the second is the topic.

Retreive or set a channel’s topic.

Examples

irc_instance.topic('#asl', 'Laaaadddddiiiiiieeeeeesssssss'); // Set a channel topic
irc_instance.topic('#asl', function (c, t) {
    print('Topic in ' + c + ' is: ' + t);
});