File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
frontend/src/components/Navbar Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ import {
1212import React , { useMemo } from 'react' ;
1313import { RoleProtected } from 'components/RoleProtected' ;
1414import { UserRole } from '@auto-drive/models' ;
15+ import dayjs from 'dayjs' ;
1516import { AccountInformation } from '@/components/AccountInformation' ;
1617import { useUserStore } from 'globalStates/user' ;
1718import { usePathname } from 'next/navigation' ;
@@ -65,8 +66,8 @@ export const SideNavbar = ({ networkId }: SideNavbarProps) => {
6566 const subscription = useUserStore ( ( { subscription } ) => subscription ) ;
6667
6768 const renewalDate = useMemo ( ( ) => {
68- const date = new Date ( ) ;
69- return new Date ( date . getFullYear ( ) , date . getMonth ( ) + 1 , 0 ) ;
69+ const date = dayjs ( ) . add ( 1 , 'month' ) . startOf ( 'month' ) ;
70+ return date . toDate ( ) ;
7071 } , [ ] ) ;
7172
7273 return (
You can’t perform that action at this time.
0 commit comments