Skip to content
This repository was archived by the owner on Jul 30, 2025. It is now read-only.

Commit b835ffb

Browse files
myan9starpit
authored andcommitted
fix(packages/core): pry-client fails when an external kui client doesn't have invisible-global-input in index.html
Fixes #4505
1 parent aef0ee1 commit b835ffb

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

packages/core/src/webapp/queueing.ts

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,18 @@ export const disableInputQueueing = (tab: Tab): string => {
6969
document.body.removeEventListener('keydown', tab.queueListener)
7070
}
7171

72-
// here is what might have queued up
73-
const queuedInput = invisibleHand.value
72+
let queuedInput = ''
7473

75-
// reset the queueing state
76-
invisibleHand.value = ''
74+
if (invisibleHand) {
75+
// here is what might have queued up
76+
queuedInput = invisibleHand.value
7777

78-
// this can be expensive; callers MUST focus on their element if they want this behavior
79-
// invisibleHand.blur()
78+
// reset the queueing state
79+
invisibleHand.value = ''
80+
81+
// this can be expensive; callers MUST focus on their element if they want this behavior
82+
// invisibleHand.blur()
83+
}
8084

8185
return queuedInput
8286
}

0 commit comments

Comments
 (0)