detail
Root cause of USR369 seeing count:1060 on a system-scoped mail query: action=list's SQL never used the $_GET['system'] param at all, always returned every message ever sent platform-wide. pickup action (delivered=0 per system) was already correct and unaffected -- SYNC.php's real 75-item backlog was accurate the whole time, only the list/audit view was misleading. Added system= and unread=1 params, backward compatible (no params = old full-history behavior preserved). Backed up original first (BACKUP.php), syntax-checked via self-deleting php -l bootstrap in backend/tmp/ before touching live file, then live-tested 4 scenarios post-deploy.