diff src/heartbeat.js.luan @ 89:3053a4fc10be

spy
author Franklin Schmidt <fschmidt@gmail.com>
date Thu, 13 Mar 2025 17:56:39 -0600
parents 2158a5950fcd
children c41e200c3e76
line wrap: on
line diff
--- a/src/heartbeat.js.luan	Thu Mar 13 16:18:39 2025 -0600
+++ b/src/heartbeat.js.luan	Thu Mar 13 17:56:39 2025 -0600
@@ -25,7 +25,10 @@
 
 return function()
 	local user = current_user() or error()
-	set_online(user)
+	local spy = Http.request.cookies.spy ~= nil
+	if not spy then
+		set_online(user)
+	end
 	Io.stdout = Http.response.text_writer()
 
 	local last_update = Http.request.parameters.last_update or error()