mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2026-01-31 04:42:09 -08:00
Small fix (#16872)
* small fix, prevent annoying error log when registering keydown esc from user custom js * Update script.js Co-authored-by: missionfloyd <missionfloyd@users.noreply.github.com> --------- Co-authored-by: missionfloyd <missionfloyd@users.noreply.github.com>
This commit is contained in:
parent
d8688def65
commit
e7edad6fe9
1 changed files with 1 additions and 1 deletions
|
|
@ -182,7 +182,7 @@ document.addEventListener('keydown', function(e) {
|
|||
const lightboxModal = document.querySelector('#lightboxModal');
|
||||
if (!globalPopup || globalPopup.style.display === 'none') {
|
||||
if (document.activeElement === lightboxModal) return;
|
||||
if (interruptButton.style.display === 'block') {
|
||||
if (interruptButton?.style.display === 'block') {
|
||||
interruptButton.click();
|
||||
e.preventDefault();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue