changeset 333:8821a772799a

Merge
author Kim Alvefur <zash@zash.se>
date Thu, 03 Feb 2011 23:57:54 +0100
parents febfb59502fc (diff) d9c1231db77b (current diff)
children 54d4445cc5c6
files
diffstat 2 files changed, 15 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mod_ircd/mod_ircd.lua	Thu Feb 03 22:44:02 2011 +0100
+++ b/mod_ircd/mod_ircd.lua	Thu Feb 03 23:57:54 2011 +0100
@@ -136,6 +136,11 @@
 	session.send(":"..session.host.." 001 "..session.nick.." :Welcome to XMPP via the "..session.host.." gateway "..session.nick);
 end
 
+function commands.USER(session, params)
+	-- FIXME
+	-- Empty command for now
+end
+
 local joined_mucs = {};
 function commands.JOIN(session, channel)
 	if not session.nick then
@@ -165,6 +170,7 @@
 				body = "\1ACTION ".. body:sub(5) .. "\1"
 			end
 			session.send(":"..nick.." PRIVMSG "..channel.." :"..body);
+			--FIXME PM's probably won't work
 		end
 	end);
 end
@@ -226,6 +232,13 @@
 	session.send(":"..session.host.." 324 "..session.nick.." "..channel.." +J"); 
 end
 
+function commands.QUIT(session, message)
+	session.send("ERROR :Closing Link: "..session.nick);
+	for _, room in pairs(session.rooms) do
+		room:leave(message);
+	end
+	session:close();
+end
 
 function commands.RAW(session, data)
 	--c:send(data)
--- a/mod_ircd/squishy	Thu Feb 03 22:44:02 2011 +0100
+++ b/mod_ircd/squishy	Thu Feb 03 23:57:54 2011 +0100
@@ -1,6 +1,6 @@
-Output "mod_ircd.lua"
+Output "mod_ircd.out.lua"
 
 -- In theory, you should be able to leave all but verses groupchat plugin
 Module "verse" "verse.lua"
 
-Main "mod_ircd.out.lua"
+Main "mod_ircd.lua"