Unverified Commit 95182480 authored by Furkan MT's avatar Furkan MT Committed by GitHub

fixes #30604 - Cannot read properties of null (reading 'tagName') (#30919)

* Cannot read properties of null (reading 'tagName')

https://github.com/vercel/next.js/issues/30604Co-authored-by: 's avatarSteven <steven@ceriously.com>
parent c6c24030
......@@ -62,7 +62,7 @@ function updateElements(type: string, components: JSX.Element[]): void {
i < headCount;
i++, j = j!.previousElementSibling
) {
if (j!.tagName.toLowerCase() === type) {
if (j?.tagName?.toLowerCase() === type) {
oldTags.push(j!)
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment