Skip to content

Commit

Permalink
docs: update the accepted type for key
Browse files Browse the repository at this point in the history
  • Loading branch information
nperez0111 authored Mar 10, 2024
1 parent d8b98c2 commit 4290ad3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/parseHotkeys.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const mappedKeys: Record<string, string> = {
ControlRight: 'ctrl',
}

export function mapKey(key: string): string {
export function mapKey(key?: string): string {
return (mappedKeys[key] || key || '')
.trim()
.toLowerCase()
Expand Down

0 comments on commit 4290ad3

Please sign in to comment.