Hide members excluded by invitation policy in Android snapshots
This commit is contained in:
1 parent
48761ff473
commit
cb9036d54c
1 file changed
+3
-2
@@ -466,7 +466,7 @@ char* utun_bridge_get_channels_json(void) {
|
||||
snprintf(preview, sizeof(preview), "%s: %s", author_name, body);
|
||||
} else if (last_rc != SQLITE_DONE) goto failed;
|
||||
sqlite3_finalize(last); last = NULL;
|
||||
snprintf(sql, sizeof(sql), "SELECT DISTINCT node_id FROM \"%s\"", peers_table);
|
||||
snprintf(sql, sizeof(sql), "SELECT node_id FROM \"%s\" WHERE admitted=1", peers_table);
|
||||
if (sqlite3_prepare_v2(db, sql, -1, &peers, NULL) != SQLITE_OK) goto failed;
|
||||
int online = 0, peer_rc;
|
||||
while ((peer_rc = sqlite3_step(peers)) == SQLITE_ROW) {
|
||||
@@ -765,7 +765,8 @@ char* utun_bridge_get_channel_members_json(const char* channel_id) {
|
||||
"SELECT p.node_id,COALESCE(n.name,''),COALESCE(p.local_nick,''),COALESCE(p.adm_tags,''),"
|
||||
"COALESCE(p.node_type,0),COALESCE(p.node_RTT,0),COALESCE(p.storage,0),COALESCE(p.userinfo,''),"
|
||||
"p.source,length(p.adm_tags_sig),COALESCE(p.deleted,0),p.radio_muted"
|
||||
" FROM \"%s\" p LEFT JOIN nodes n ON p.node_id=n.node_id ORDER BY p.node_id ASC", peers_tbl);
|
||||
" FROM \"%s\" p LEFT JOIN nodes n ON p.node_id=n.node_id"
|
||||
" WHERE p.admitted=1 OR p.source!=0 OR p.deleted!=0 ORDER BY p.node_id ASC", peers_tbl);
|
||||
struct strbuf out = strbuf_new();
|
||||
sqlite3_stmt* st = NULL;
|
||||
int rc = sqlite3_prepare_v2(db, sql, -1, &st, NULL);
|
||||
|
||||
Reference in new issue
Block a user