commit | 9501f90d88b95847fc3616ed5e4330cf5bfa92a8 | [log] [tgz] |
---|---|---|
author | Ben Rohlfs <brohlfs@google.com> | Fri Dec 04 08:12:35 2020 +0100 |
committer | Ben Rohlfs <brohlfs@google.com> | Fri Dec 04 11:33:21 2020 +0100 |
tree | 7b5393105ddc14514126cfc619889d62d487d03d | |
parent | a6b4ae21d994e1456d15b2ca8d8a6954a13031a8 [diff] |
Remove errFn from getGroupMembers Change-Id: I27b6be100b2a901f0a5b2bf4968a8e10c7e6a3d2
diff --git a/polygerrit-ui/app/elements/shared/gr-rest-api-interface/gr-rest-api-interface.ts b/polygerrit-ui/app/elements/shared/gr-rest-api-interface/gr-rest-api-interface.ts index 410140c..580a75c 100644 --- a/polygerrit-ui/app/elements/shared/gr-rest-api-interface/gr-rest-api-interface.ts +++ b/polygerrit-ui/app/elements/shared/gr-rest-api-interface/gr-rest-api-interface.ts
@@ -537,16 +537,12 @@ ); } - getGroupMembers( - groupName: GroupId | GroupName, - errFn?: ErrorCallback - ): Promise<AccountInfo[] | undefined> { + getGroupMembers(groupName: GroupId | GroupName): Promise<AccountInfo[]> { const encodeName = encodeURIComponent(groupName); - return this._restApiHelper.fetchJSON({ + return (this._restApiHelper.fetchJSON({ url: `/groups/${encodeName}/members/`, - errFn, anonymizedUrl: '/groups/*/members', - }) as Promise<AccountInfo[] | undefined>; + }) as unknown) as Promise<AccountInfo[]>; } getIncludedGroup(
diff --git a/polygerrit-ui/app/services/services/gr-rest-api/gr-rest-api.ts b/polygerrit-ui/app/services/services/gr-rest-api/gr-rest-api.ts index 8fc1935..8f11a60 100644 --- a/polygerrit-ui/app/services/services/gr-rest-api/gr-rest-api.ts +++ b/polygerrit-ui/app/services/services/gr-rest-api/gr-rest-api.ts
@@ -636,10 +636,7 @@ errFn?: ErrorCallback ): Promise<GroupAuditEventInfo[] | undefined>; - getGroupMembers( - groupName: GroupId | GroupName, - errFn?: ErrorCallback - ): Promise<AccountInfo[] | undefined>; + getGroupMembers(groupName: GroupId | GroupName): Promise<AccountInfo[]>; getIncludedGroup( groupName: GroupId | GroupName