Skip to content

Commit

Permalink
Added early return to modals.init() if modal undefined to support…
Browse files Browse the repository at this point in the history
  • Loading branch information
kudo-sync-bot committed Jan 13, 2025
1 parent 83ad1b8 commit 121476a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions firefox/extension/components/modals.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ window.modals = {
},

init(modal) {
if (!modal) return // to support non-div this.open()s
if (!this.styles) this.stylize() // to init/append stylesheet
modal.classList.add('no-user-select', this.class) ; modal.parentNode.classList.add(`${this.class}-bg`)
dom.fillStarryBG(modal) // add starry bg
Expand Down

0 comments on commit 121476a

Please sign in to comment.