-
Notifications
You must be signed in to change notification settings - Fork 17
Open
Description
When processing at-rules, postcss-functions expect the node to have a "params" entry but not all at-rules have params. So node.params can be undefined and cause an error when passed to postcss-value-parser.
postcss-functions/src/lib/transformer.mjs
Lines 65 to 69 in d834e0a
| export function transformAtRule(node, functions) { | |
| return then(transformString(node.params, functions), value => { | |
| node.params = value; | |
| }); | |
| } |
The transformString() function should check if a proper string is supplied and fallback to an empty string or avoid parsing if not.
I never had any troubles with PostCSS and font-face rules before. I only notice this bug after a recent update. Apparently my occurrence of the bug is triggered by postcss-font-magician which inject its own at-rules with no params entry (which is not a bug).
ethan-jones-vizio, ryansch and pix666
Metadata
Metadata
Assignees
Labels
No labels