@ -34,7 +34,7 @@ const useAccount = (accountId?: string, withRelationship = false) => {
|
||||
queryKey: ['accounts', accountId],
|
||||
queryFn: async () => {
|
||||
const account = await client.accounts.getAccount(accountId!);
|
||||
queryClient.setQueryData(['accounts', 'lookup', account.acct.toLowerCase()], account);
|
||||
queryClient.setQueryData(['accounts', 'lookup', account.acct.toLowerCase()], account.id);
|
||||
return account;
|
||||
},
|
||||
enabled: !!accountId,
|
||||
|
||||
@ -14,7 +14,7 @@ const useAccounts = (accountIds: Array<string>) => {
|
||||
queryKey: ['accounts', accountId],
|
||||
queryFn: async () => {
|
||||
const response = await client.accounts.getAccount(accountId);
|
||||
queryClient.setQueryData(['accounts', 'lookup', response.acct.toLowerCase()], response);
|
||||
queryClient.setQueryData(['accounts', 'lookup', response.acct.toLowerCase()], response.id);
|
||||
return response;
|
||||
},
|
||||
enabled: !!accountId,
|
||||
|
||||
Reference in New Issue
Block a user