Add streak metrics to profile component
cgen-8af654bdc52b4304980100342455b265
This commit is contained in:
parent
198f3f8369
commit
cbe652fbc2
1 changed files with 3 additions and 0 deletions
|
|
@ -161,6 +161,9 @@ export default function Profile() {
|
|||
},
|
||||
]);
|
||||
|
||||
const currentStreak = profile?.current_streak ?? 0;
|
||||
const longestStreak = profile?.longest_streak ?? currentStreak;
|
||||
|
||||
useEffect(() => {
|
||||
if (!authLoading && !user) {
|
||||
navigate('/login');
|
||||
|
|
|
|||
Loading…
Reference in a new issue