Fix double registration of navigation commands

This commit is contained in:
Jackson Harper
2023-09-01 14:15:48 +08:00
parent 92e654f311
commit a2f339ceed
2 changed files with 3 additions and 3 deletions

View File

@ -15,7 +15,9 @@ export function navigationCommands(
shortcutKeys: ['b'],
actionDescription: 'Go back',
shortcutKeyDescription: 'b',
callback: () => router?.back(),
callback: () => {
router?.back()
},
},
]
}

View File

@ -79,8 +79,6 @@ export default function Home(): JSX.Element {
})
}, [articleData?.article.article])
useKeyboardShortcuts(navigationCommands(router))
const actionHandler = useCallback(
async (action: string, arg?: unknown) => {
switch (action) {