From 421a2e258327f7609ece4166e1bff2abe920282b Mon Sep 17 00:00:00 2001 From: Clinton Fray Date: Wed, 5 Oct 2022 22:48:27 +0200 Subject: [PATCH] fix: #48 check if hotkeys is defined --- src/components/options/editor/Editor.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/options/editor/Editor.js b/src/components/options/editor/Editor.js index 5b93814..31bd696 100644 --- a/src/components/options/editor/Editor.js +++ b/src/components/options/editor/Editor.js @@ -319,7 +319,7 @@ class Editor extends React.Component { const hotkeyOptions = Array.from(Array(9).keys()) - const currentHotkeys = current.hotkeys.filter((e) => e !== null) + const currentHotkeys = current.hotkeys ? current.hotkeys.filter((e) => e !== null) : [] console.log('CH', currentHotkeys)