kopia lustrzana https://gitlab.com/soapbox-pub/soapbox
think before you copy n paste
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>datepicker-css
rodzic
b744cc5580
commit
25ceec244d
|
@ -425,8 +425,7 @@ export function subscribeAccount(id, notifications) {
|
||||||
dispatch(subscribeAccountRequest(id));
|
dispatch(subscribeAccountRequest(id));
|
||||||
|
|
||||||
api(getState).post(`/api/v1/pleroma/accounts/${id}/subscribe`, { notifications }).then(response => {
|
api(getState).post(`/api/v1/pleroma/accounts/${id}/subscribe`, { notifications }).then(response => {
|
||||||
// Pass in entire statuses map so we can use it to filter stuff in different parts of the reducers
|
dispatch(subscribeAccountSuccess(response.data));
|
||||||
dispatch(subscribeAccountSuccess(response.data, getState().get('statuses')));
|
|
||||||
}).catch(error => {
|
}).catch(error => {
|
||||||
dispatch(subscribeAccountFail(id, error));
|
dispatch(subscribeAccountFail(id, error));
|
||||||
});
|
});
|
||||||
|
@ -454,11 +453,10 @@ export function subscribeAccountRequest(id) {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
export function subscribeAccountSuccess(relationship, statuses) {
|
export function subscribeAccountSuccess(relationship) {
|
||||||
return {
|
return {
|
||||||
type: ACCOUNT_SUBSCRIBE_SUCCESS,
|
type: ACCOUNT_SUBSCRIBE_SUCCESS,
|
||||||
relationship,
|
relationship,
|
||||||
statuses,
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue