Don't try to access target when it doesn't exist

This commit is contained in:
Râu Cao 2023-03-18 12:13:53 +07:00
parent beaafa5d7e
commit 2cced696f5
Signed by: raucao
GPG Key ID: 15E65F399D084BA9

View File

@ -20,7 +20,9 @@ export default class extends Controller {
} }
if (window.nostr) { if (window.nostr) {
this.setPubkeyTarget.disabled = false if (this.hasSetPubkeyTarget) {
this.setPubkeyTarget.disabled = false
}
} else { } else {
this.noExtensionTarget.classList.remove("hidden") this.noExtensionTarget.classList.remove("hidden")
} }