mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-04-16 12:06:55 +02:00
Fix to member listing: I wanted an object with member IDs as keys and member revisions as values, not an array.
This commit is contained in:
parent
3f8a5b8b76
commit
7c761dea72
1 changed files with 2 additions and 3 deletions
|
@ -1395,13 +1395,12 @@ unsigned int SqliteNetworkController::_doCPGet(
|
|||
sqlite3_reset(_sListNetworkMembers);
|
||||
sqlite3_bind_text(_sListNetworkMembers,1,nwids,16,SQLITE_STATIC);
|
||||
while (sqlite3_step(_sListNetworkMembers) == SQLITE_ROW) {
|
||||
responseBody.append((responseBody.length() > 0) ? ",{\"" : "[{\"");
|
||||
responseBody.append((responseBody.length() > 0) ? ",\"" : "{\"");
|
||||
responseBody.append((const char *)sqlite3_column_text(_sListNetworkMembers,0));
|
||||
responseBody.append("\":");
|
||||
responseBody.append((const char *)sqlite3_column_text(_sListNetworkMembers,1));
|
||||
responseBody.push_back('}');
|
||||
}
|
||||
responseBody.push_back(']');
|
||||
responseBody.push_back('}');
|
||||
responseContentType = "application/json";
|
||||
return 200;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue