mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-30 20:14:49 +00:00
conditional for elem
This commit is contained in:
committed by
Aiden McClelland
parent
313729146e
commit
14a0dbe66e
@@ -30,7 +30,7 @@ export class AppComponent {
|
|||||||
|
|
||||||
const elems = document.getElementsByClassName('enter-click')
|
const elems = document.getElementsByClassName('enter-click')
|
||||||
const elem = elems[elems.length - 1] as HTMLButtonElement
|
const elem = elems[elems.length - 1] as HTMLButtonElement
|
||||||
if (elem.classList.contains('no-click')) return
|
if (!elem || elem.classList.contains('no-click')) return
|
||||||
if (elem) elem.click()
|
if (elem) elem.click()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user