mirror of
https://github.com/nunocoracao/blowfish.git
synced 2026-10-10 22:09:31 +00:00
The global keydown handler calls event.key.toLowerCase() without checking that event.key is defined. Some keydown events carry no key property (browser autofill, IME composition, some mobile virtual keyboards), which throws TypeError: Cannot read properties of undefined (reading 'toLowerCase') and breaks the handler for that keystroke. Add a truthiness guard before calling toLowerCase(), matching the style already used for the other event.key comparisons in the same handler. No behavior change for real Cmd/Ctrl+K presses.