Skip to content

Commit

Permalink
Refactor cached_at
Browse files Browse the repository at this point in the history
  • Loading branch information
SnowCait committed Oct 29, 2023
1 parent b0030f0 commit f96a95b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions web/src/routes/(app)/home/FollowingTimeline.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@
});
const storage = new WebStorage(localStorage);
const cachedAt = storage.get('cached_at');
const cachedAt = storage.getCachedAt();
const authorFilter: Filter = {
kinds: [...new Set(authorReplaceableKinds.map(({ kind }) => kind))],
authors: [$pubkey],
since: cachedAt === null ? now : Number(cachedAt)
since: cachedAt ?? now
};
console.log('[author filter]', authorFilter, new Date((authorFilter.since ?? 0) * 1000));
Expand Down

0 comments on commit f96a95b

Please sign in to comment.