diff --git a/builtin/game/mod_profiling.lua b/builtin/game/mod_profiling.lua
index 0fe99e72555c388262026517979cd130909e3290..df2d10221de28c2cd19bda51e01161f64fbe9895 100644
--- a/builtin/game/mod_profiling.lua
+++ b/builtin/game/mod_profiling.lua
@@ -309,9 +309,10 @@ local function initialize_profiling()
 			mod_statistics.entity_callbacks[cbid] = prototype.get_staticdata
 			new_get_staticdata = function(self)
 				local starttime = core.get_us_time()
-				mod_statistics.entity_callbacks[cbid](self)
+				local retval = mod_statistics.entity_callbacks[cbid](self)
 				local delta = core.get_us_time() -starttime
 				mod_statistics.log_time(cbid, modname, delta)
+				return retval
 			end
 		end