Reduce account overfetching when displaying collection lists (#39220)
This commit is contained in:
1 parent
8e15e49e87
commit
0caf334891
6 files changed
+48
-5
No files matched your search
@@ -19,6 +19,11 @@ import type {
|
||||
ApiProfileUpdateParams,
|
||||
} from '../api_types/profile';
|
||||
|
||||
export const apiGetAccounts = (ids: string[]) =>
|
||||
apiRequestGet<ApiAccountJSON[]>('v1/accounts', {
|
||||
id: ids,
|
||||
});
|
||||
|
||||
export const apiSubmitAccountNote = (id: string, value: string) =>
|
||||
apiRequestPost<ApiRelationshipJSON>(`v1/accounts/${id}/note`, {
|
||||
comment: value,
|
||||
|
||||
@@ -15,7 +15,7 @@ export const apiUpdate = (list: Partial<ApiListJSON>) =>
|
||||
|
||||
export const apiGetLists = () => apiRequestGet<ApiListJSON[]>('v1/lists');
|
||||
|
||||
export const apiGetAccounts = (listId: string) =>
|
||||
export const apiGetListAccounts = (listId: string) =>
|
||||
apiRequestGet<ApiAccountJSON[]>(`v1/lists/${listId}/accounts`, {
|
||||
limit: 0,
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user