Skip to content

Commit a23712b

Browse files
committed
fix(navbar): navigate based on route name instead of path in dropdown
1 parent 7ff7499 commit a23712b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/common/navbar/NavbarSettingsDopdown.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ const onSelect: DropdownProps['onSelect'] = async (key: string, { label }) => {
145145
case 'logout':
146146
return logout();
147147
default:
148-
if (Object.values(Route).includes(key as Route)) return router.push(`/${key}`);
148+
if (Object.values(Route).includes(key as Route)) return router.push({ name: key });
149149
if (typeof label === 'string' && key.startsWith('user-')) {
150150
return loadUser(label);
151151
}

0 commit comments

Comments
 (0)