mirror of
https://github.com/glitch-soc/mastodon.git
synced 2024-11-25 01:24:02 -05:00
When submitting markers, use last displayed notification, not last received one
This commit is contained in:
parent
e135b293fa
commit
4cd2d13bd2
@ -9,7 +9,7 @@ export const submitMarkers = () => (dispatch, getState) => {
|
|||||||
const params = {};
|
const params = {};
|
||||||
|
|
||||||
const lastHomeId = getState().getIn(['timelines', 'home', 'items', 0]);
|
const lastHomeId = getState().getIn(['timelines', 'home', 'items', 0]);
|
||||||
const lastNotificationId = getState().getIn(['notifications', 'items', 0, 'id']);
|
const lastNotificationId = getState().getIn(['notifications', 'lastReadId']);
|
||||||
|
|
||||||
if (lastHomeId) {
|
if (lastHomeId) {
|
||||||
params.home = {
|
params.home = {
|
||||||
@ -17,7 +17,7 @@ export const submitMarkers = () => (dispatch, getState) => {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (lastNotificationId) {
|
if (lastNotificationId && lastNotificationId !== '0') {
|
||||||
params.notifications = {
|
params.notifications = {
|
||||||
last_read_id: lastNotificationId,
|
last_read_id: lastNotificationId,
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user