mirror of
https://git.bsd.gay/fef/nyastodon.git
synced 2024-12-24 03:43:42 +01:00
Fix #449 - don't do relationships fetch for empty array of IDs
This commit is contained in:
parent
cc1eccc8bc
commit
1d5cbfa356
1 changed files with 4 additions and 0 deletions
|
@ -486,6 +486,10 @@ export function expandFollowingFail(id, error) {
|
|||
|
||||
export function fetchRelationships(account_ids) {
|
||||
return (dispatch, getState) => {
|
||||
if (account_ids.length === 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
dispatch(fetchRelationshipsRequest(account_ids));
|
||||
|
||||
api(getState).get(`/api/v1/accounts/relationships?${account_ids.map(id => `id[]=${id}`).join('&')}`).then(response => {
|
||||
|
|
Loading…
Reference in a new issue