mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-07-06 21:04:20 +00:00
97588dd0b9
disableInvalidClients evaluated the depleted predicate twice per poll: once to SELECT the rows (for xray removal and settings sync) and again in the UPDATE that flips enable off — each a full client_traffics scan, the second also re-running the cross-panel EXISTS subquery when global rows exist. The UPDATE now flips the already-collected rows by primary key in sqlInChunk batches, sorted for stable lock order. Same rows, same RowsAffected, half the scan cost; id-based matching also stays correct for rows with empty emails.