File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -634,7 +634,8 @@ module.exports = {
634
634
const attrGroups = { }
635
635
tag . attributes . forEach ( attr => {
636
636
if ( [ 'location' ] . includes ( attr . key . name ) ) {
637
- ( attrGroups [ attr . key . name ] ??= [ ] ) . push ( attr )
637
+ attrGroups [ attr . key . name ] = attrGroups [ attr . key . name ] ?? [ ]
638
+ attrGroups [ attr . key . name ] . push ( attr )
638
639
}
639
640
} )
640
641
Object . values ( attrGroups ) . forEach ( attrGroup => {
@@ -648,8 +649,8 @@ module.exports = {
648
649
node : head ,
649
650
fix ( fixer ) {
650
651
return [
651
- fixer . replaceText ( head . value , `"${ attrGroup . map ( a => a . value . value ) . join ( " " ) } "` ) ,
652
- ...tail . map ( a => fixer . remove ( a ) )
652
+ fixer . replaceText ( head . value , `"${ attrGroup . map ( a => a . value . value ) . join ( ' ' ) } "` ) ,
653
+ ...tail . map ( a => fixer . remove ( a ) ) ,
653
654
]
654
655
} ,
655
656
} )
You can’t perform that action at this time.
0 commit comments