plugins/autosubscribe.lua

Mon, 17 Sep 2018 14:46:47 +0100

author
Matthew Wild <mwild1@gmail.com>
date
Mon, 17 Sep 2018 14:46:47 +0100
changeset 151
936364f8efcf
parent 19
a698d64fc929
permissions
-rw-r--r--

Dockerfile: Switch to alpine for final image


function riddim.plugins.autosubscribe(bot)
	bot:hook("presence", function (presence)
		if presence.stanza.attr.type ~= 'subscribe' then return nil; end
		bot:send_presence(presence.sender.jid, 'subscribed');
		return false;
	end);
end

mercurial