Diff

mod_sentry/sentry.lib.lua @ 4289:de91b7cb7342

mod_sentry: Fix to correctly iterate over traceback
author Matthew Wild <mwild1@gmail.com>
date Wed, 09 Dec 2020 16:22:22 +0000
parent 4288:26bc1ae88ccb
child 4291:a0d20e378670
line wrap: on
line diff
--- a/mod_sentry/sentry.lib.lua	Wed Dec 09 16:22:04 2020 +0000
+++ b/mod_sentry/sentry.lib.lua	Wed Dec 09 16:22:22 2020 +0000
@@ -70,8 +70,8 @@
 	};
 	local traceback = e.context.traceback;
 	if traceback and type(traceback) == "table" then
-		for i = #traceback, 1 do
 		local frames = array();
+		for i = #traceback, 1, -1 do
 			local frame = traceback[i];
 			table.insert(frames, {
 				["function"] = frame.info.name;