From eb2a563a9bf6d90dfedf862226b5a80321fa0187 Mon Sep 17 00:00:00 2001 From: dominikg Date: Tue, 8 Nov 2022 21:26:12 +0100 Subject: [PATCH] fix: only read static value for rel attribute validation --- src/compiler/compile/nodes/Element.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/compiler/compile/nodes/Element.ts b/src/compiler/compile/nodes/Element.ts index 303b2e9122..0b7229d55b 100644 --- a/src/compiler/compile/nodes/Element.ts +++ b/src/compiler/compile/nodes/Element.ts @@ -620,7 +620,7 @@ export default class Element extends Node { if (href_static_value === null || href_static_value.match(/^(https?:)?\/\//i)) { const rel = attribute_map.get('rel'); - const rel_values = rel ? rel.get_static_value().split(' ') : []; + const rel_values = rel?.is_static ? rel.get_static_value().split(' ') : []; const expected_values = ['noreferrer']; expected_values.forEach(expected_value => {