fix: replace incorrect typeof usage with proper undefined check

This commit is contained in:
Narek Zakarian 2025-07-02 17:47:54 +04:00
parent 3ab7fe0af3
commit 9d16c2d680
No known key found for this signature in database
GPG key ID: 07AFD7E7A9C164A7

View file

@ -5,7 +5,7 @@ document.addEventListener( 'DOMContentLoaded', () => {
);
const link = document.querySelector( 'a.settings-switch-ui' );
if ( ! typeof config || ( ! button && ! link ) ) {
if ( typeof config === 'undefined' || ( ! button && ! link ) ) {
return;
}