happy-dom icon indicating copy to clipboard operation
happy-dom copied to clipboard

Problems with "parseCSSRules" function while running tests

Open rDieCbw opened this issue 1 year ago • 2 comments

Describe the bug Sometimes, on my stack the object extracted on "for of" loop is undefined and when the first if tries to access the "rule.type" key, the whole thing fails.

Expected behavior It suposed to have any validation on the object, just like you have done in this commit

Only adding the validation like rule && ... works like charm

rDieCbw avatar Aug 08 '23 23:08 rDieCbw

Can you provide a reproduction link? Easy to locate and troubleshoot problems.

btea avatar Aug 15 '23 14:08 btea

I have looked at the code and I have a hard time to see how this could happen. A link or some more information would be great.

capricorn86 avatar Aug 16 '23 15:08 capricorn86