mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2026-01-11 01:44:50 +08:00
fix(event-handlers): commandOverride not working due to incorrect check (@byseif21) (#7330)
it returns null when attribute doesn't exist, not undefined
This commit is contained in:
parent
e2d9b79332
commit
69cc227c87
1 changed files with 1 additions and 1 deletions
|
|
@ -24,7 +24,7 @@ const testPage = qs(".pageTest");
|
|||
testPage?.onChild("click", "#testModesNotice .textButton", async (event) => {
|
||||
const target = event.childTarget as HTMLElement;
|
||||
const attr = target?.getAttribute("commands");
|
||||
if (attr === undefined) return;
|
||||
if (attr === null) return;
|
||||
Commandline.show({ subgroupOverride: attr as ConfigKey | ListsObjectKeys });
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue