mirror of
https://github.com/vale981/tridactyl
synced 2025-03-05 09:31:41 -05:00
Merge pull request #2234 from saulrh/parser_keys_on_exstr
Return keys=[] from parser so things don't blow up if exstr is ""
This commit is contained in:
commit
ead0d0b914
2 changed files with 2 additions and 1 deletions
|
@ -3452,7 +3452,7 @@ export async function unbind(...args: string[]) {
|
|||
export async function unbindurl(pattern: string, mode: string, keys: string) {
|
||||
const args_obj = parse_bind_args(mode, keys)
|
||||
|
||||
return config.setURL(pattern, args_obj.configName, args_obj.key, "")
|
||||
return config.setURL(pattern, args_obj.configName, args_obj.key, null)
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -169,6 +169,7 @@ export function parse(keyseq: KeyEventLike[], map: KeyMap): ParserResponse {
|
|||
exstr: perfect[1] + numericPrefixToExstrSuffix(numericPrefix),
|
||||
isMatch: true,
|
||||
numericPrefix: numericPrefix.length ? Number(numericPrefix.map(ke => ke.key).join("")) : undefined,
|
||||
keys: [],
|
||||
}
|
||||
} catch (e) {
|
||||
if (!(e instanceof RangeError)) throw e
|
||||
|
|
Loading…
Add table
Reference in a new issue