Page MenuHomePhabricator

D8330.diff
No OneTemporary

D8330.diff

diff --git a/keyserver/src/fetchers/user-fetchers.js b/keyserver/src/fetchers/user-fetchers.js
--- a/keyserver/src/fetchers/user-fetchers.js
+++ b/keyserver/src/fetchers/user-fetchers.js
@@ -374,6 +374,12 @@
return row.username;
}
+async function fetchAllUsernames(): Promise<string[]> {
+ const query = SQL`SELECT username FROM users`;
+ const [result] = await dbQuery(query);
+ return result.map(row => row.username);
+}
+
async function fetchKeyserverAdminID(): Promise<?string> {
const changeRoleExtractString = `$.${threadPermissions.CHANGE_ROLE}`;
const query = SQL`
@@ -415,6 +421,7 @@
fetchCurrentUserInfo,
fetchAllUserIDs,
fetchUsername,
+ fetchAllUsernames,
fetchKnownUserInfos,
fetchKeyserverAdminID,
fetchUserIDForEthereumAddress,

File Metadata

Mime Type
text/plain
Expires
Tue, Nov 26, 7:47 PM (21 h, 8 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2585949
Default Alt Text
D8330.diff (779 B)

Event Timeline