mod_pastebin/mod_pastebin.lua
changeset 454 3f101f7a26d0
parent 446 56f1c29ee7f1
child 501 e851f386c904
equal deleted inserted replaced
453:1969310ea06a 454:3f101f7a26d0
   134 	
   134 	
   135 	base_url = base_url or ("http://"..module:get_host()..(port ~= 80 and (":"..port) or "").."/"..base.."/");
   135 	base_url = base_url or ("http://"..module:get_host()..(port ~= 80 and (":"..port) or "").."/"..base.."/");
   136 	
   136 	
   137 	httpserver.new{ port = port, base = base, handler = handle_request, ssl = ssl }
   137 	httpserver.new{ port = port, base = base, handler = handle_request, ssl = ssl }
   138 end
   138 end
       
   139 
       
   140 function module.save()
       
   141 	return { pastes = pastes };
       
   142 end
       
   143 
       
   144 function module.restore(data)
       
   145 	pastes = data.pastes or pastes;
       
   146 end