Fix code discrepancies with upstream
This commit is contained in:
parent
d358a3cc61
commit
f69f1e9429
|
@ -211,7 +211,7 @@ export function bookmark(status) {
|
||||||
|
|
||||||
api(getState).post(`/api/v1/statuses/${status.get('id')}/bookmark`).then(function (response) {
|
api(getState).post(`/api/v1/statuses/${status.get('id')}/bookmark`).then(function (response) {
|
||||||
dispatch(importFetchedStatus(response.data));
|
dispatch(importFetchedStatus(response.data));
|
||||||
dispatch(bookmarkSuccess(status));
|
dispatch(bookmarkSuccess(status, response.data));
|
||||||
}).catch(function (error) {
|
}).catch(function (error) {
|
||||||
dispatch(bookmarkFail(status, error));
|
dispatch(bookmarkFail(status, error));
|
||||||
});
|
});
|
||||||
|
@ -224,7 +224,7 @@ export function unbookmark(status) {
|
||||||
|
|
||||||
api(getState).post(`/api/v1/statuses/${status.get('id')}/unbookmark`).then(response => {
|
api(getState).post(`/api/v1/statuses/${status.get('id')}/unbookmark`).then(response => {
|
||||||
dispatch(importFetchedStatus(response.data));
|
dispatch(importFetchedStatus(response.data));
|
||||||
dispatch(unbookmarkSuccess(status));
|
dispatch(unbookmarkSuccess(status, response.data));
|
||||||
}).catch(error => {
|
}).catch(error => {
|
||||||
dispatch(unbookmarkFail(status, error));
|
dispatch(unbookmarkFail(status, error));
|
||||||
});
|
});
|
||||||
|
@ -238,10 +238,11 @@ export function bookmarkRequest(status) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export function bookmarkSuccess(status) {
|
export function bookmarkSuccess(status, response) {
|
||||||
return {
|
return {
|
||||||
type: BOOKMARK_SUCCESS,
|
type: BOOKMARK_SUCCESS,
|
||||||
status: status,
|
status: status,
|
||||||
|
response: response,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -260,10 +261,11 @@ export function unbookmarkRequest(status) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export function unbookmarkSuccess(status) {
|
export function unbookmarkSuccess(status, response) {
|
||||||
return {
|
return {
|
||||||
type: UNBOOKMARK_SUCCESS,
|
type: UNBOOKMARK_SUCCESS,
|
||||||
status: status,
|
status: status,
|
||||||
|
response: response,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue