Skip to content

Commit

Permalink
add one more guard return for findParentAndAppendEl()
Browse files Browse the repository at this point in the history
  • Loading branch information
slavaleleka committed Feb 12, 2024
1 parent f327eb2 commit a062bf8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/scriptlets/trusted-create-element.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ export function trustedCreateElement(
parentEl = document.querySelector(parentElSelector);
} catch (e) {
logError(`Cannot find parent element by selector '${parentElSelector}'`, e);
return false;
}

if (!parentEl) {
Expand Down

0 comments on commit a062bf8

Please sign in to comment.