mirror of
https://github.com/swc-project/swc.git
synced 2024-11-27 13:38:33 +03:00
fix(node-swc): Handle empty object patterns. (#1393)
Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
This commit is contained in:
parent
313f51fab1
commit
f5a90ae985
@ -1656,7 +1656,7 @@ export default class Visitor {
|
||||
}
|
||||
|
||||
visitObjectPattern(n: ObjectPattern): Pattern {
|
||||
n.props = this.visitObjectPatternProperties(n.props);
|
||||
n.props = this.visitObjectPatternProperties(n.props || []);
|
||||
n.typeAnnotation = this.visitTsTypeAnnotation(n.typeAnnotation);
|
||||
return n;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user