mirror of
https://github.com/mastodon/mastodon.git
synced 2025-09-06 18:01:05 +00:00
Fix clicking a status multiple times causing duplicate entries in browser history (#35118)
This commit is contained in:
parent
adf812efb3
commit
ac039d5f13
|
@ -300,9 +300,13 @@ class Status extends ImmutablePureComponent {
|
||||||
|
|
||||||
if (newTab) {
|
if (newTab) {
|
||||||
window.open(path, '_blank', 'noopener');
|
window.open(path, '_blank', 'noopener');
|
||||||
|
} else {
|
||||||
|
if (history.location.pathname.replace('/deck/', '/') === path) {
|
||||||
|
history.replace(path);
|
||||||
} else {
|
} else {
|
||||||
history.push(path);
|
history.push(path);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
handleHotkeyOpenProfile = () => {
|
handleHotkeyOpenProfile = () => {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user