Changeset

8714:e1c4bdb2cd25

prosody: Use prosody.log instead of _G.log because it looks nicer
author Kim Alvefur <zash@zash.se>
date Thu, 05 Apr 2018 16:00:00 +0200
parents 8713:48bd442f6d4d
children 8715:25d8d6091ec3
files prosody
diffstat 1 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/prosody	Thu Apr 05 16:01:10 2018 +0200
+++ b/prosody	Thu Apr 05 16:00:00 2018 +0200
@@ -65,10 +65,10 @@
 			return "quitting";
 		end
 
-		log("error", "Top-level error, please report:\n%s", tostring(err));
+		prosody.log("error", "Top-level error, please report:\n%s", tostring(err));
 		local traceback = debug.traceback("", 2);
 		if traceback then
-			log("error", "%s", traceback);
+			prosody.log("error", "%s", traceback);
 		end
 
 		prosody.events.fire_event("very-bad-error", {error = err, traceback = traceback});
@@ -82,15 +82,15 @@
 end
 
 local function cleanup()
-	log("info", "Shutdown status: Cleaning up");
+	prosody.log("info", "Shutdown status: Cleaning up");
 	prosody.events.fire_event("server-cleanup");
 end
 
 loop();
 
-log("info", "Shutting down...");
+prosody.log("info", "Shutting down...");
 cleanup();
 prosody.events.fire_event("server-stopped");
-log("info", "Shutdown complete");
+prosody.log("info", "Shutdown complete");
 
 os.exit(prosody.shutdown_code);