mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-02-02 22:26:57 +01:00
Fix cached statuses gone
This commit is contained in:
parent
c4236e6de7
commit
9743da1e9b
1 changed files with 2 additions and 3 deletions
|
@ -198,9 +198,7 @@ function StatusPage({ id }) {
|
|||
}
|
||||
|
||||
// RESET
|
||||
// This will probably fail when user "forward" back to open the Status page again, but gosh, too many use-cases to mimic what the browser does
|
||||
scrollOffsets.current = null;
|
||||
cachedStatusesMap.current = {};
|
||||
}, [statuses]);
|
||||
|
||||
useEffect(() => {
|
||||
|
@ -227,9 +225,10 @@ function StatusPage({ id }) {
|
|||
|
||||
useEffect(() => {
|
||||
return () => {
|
||||
// clear all scrollPositions
|
||||
// RESET
|
||||
states.scrollPositions = {};
|
||||
states.reloadStatusPage = 0;
|
||||
cachedStatusesMap.current = {};
|
||||
};
|
||||
}, []);
|
||||
|
||||
|
|
Loading…
Reference in a new issue