summaryrefslogtreecommitdiff
path: root/source/github-helpers/hotkey.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'source/github-helpers/hotkey.tsx')
-rw-r--r--source/github-helpers/hotkey.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/github-helpers/hotkey.tsx b/source/github-helpers/hotkey.tsx
index 771f3907..fac94972 100644
--- a/source/github-helpers/hotkey.tsx
+++ b/source/github-helpers/hotkey.tsx
@@ -13,10 +13,10 @@ export function registerHotkey(hotkey: string, action: VoidFunction | string): D
}
/** Safely add a hotkey to an element, preserving any existing ones and avoiding duplicates */
-export const addHotkey = (button: HTMLAnchorElement | HTMLButtonElement | undefined, hotkey: string): void => {
+export function addHotkey(button: HTMLAnchorElement | HTMLButtonElement | undefined, hotkey: string): void {
if (button) {
const hotkeys = new Set(button.dataset.hotkey?.split(','));
hotkeys.add(hotkey);
button.dataset.hotkey = [...hotkeys].join(',');
}
-};
+}