Sifa professional network API (Fastify, AT Protocol, Jetstream) sifa.id/

fix(suggestions): count only Sifa users in suggestions count (#120)

The /api/suggestions/count endpoint was counting ALL cross-network
follows (5000+), not just those who are on Sifa. Add session check
so the banner shows the correct number.

authored by

Guido X Jansen and committed by
GitHub
1019f347 03daf5f9

+2
+2
src/routes/suggestions.ts
··· 181 181 ne(connections.source, 'sifa'), 182 182 notInArray(connections.subjectDid, sifaFollowedDids), 183 183 notInArray(connections.subjectDid, dismissedDids), 184 + // Only count people who are actually on Sifa (have logged in) 185 + sql`${connections.subjectDid} IN (SELECT DISTINCT did FROM sessions)`, 184 186 ]; 185 187 186 188 if (query.since) {