Check that escape item is non-null before checking id
This commit is contained in:
parent
414540bfcb
commit
bbadeb62ac
2 changed files with 13 additions and 1 deletions
|
@ -101,7 +101,7 @@ class TouchBar extends EventEmitter {
|
|||
|
||||
const interactionListener = (event, itemID, details) => {
|
||||
let item = this.items[itemID]
|
||||
if (item == null && this.escapeItem.id === itemID) {
|
||||
if (item == null && this.escapeItem != null && this.escapeItem.id === itemID) {
|
||||
item = this.escapeItem
|
||||
}
|
||||
if (item != null && item.onInteraction != null) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue