Skip to content

Commit 9b9a346

Browse files
kettanaitoevilebottnawi
authored andcommitted
fix: adds safety check before accessing "rule parent" (#15)
1 parent 1d7291e commit 9b9a346

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -494,6 +494,7 @@ module.exports = postcss.plugin('postcss-modules-local-by-default', function(
494494

495495
css.walkRules(function(rule) {
496496
if (
497+
rule.parent &&
497498
rule.parent.type === 'atrule' &&
498499
/keyframes$/i.test(rule.parent.name)
499500
) {

0 commit comments

Comments
 (0)