diff --git a/compiler/packages/babel-plugin-react-forget/src/HIR/visitors.ts b/compiler/packages/babel-plugin-react-forget/src/HIR/visitors.ts index 0e4d4dd99b..a6e1d1816a 100644 --- a/compiler/packages/babel-plugin-react-forget/src/HIR/visitors.ts +++ b/compiler/packages/babel-plugin-react-forget/src/HIR/visitors.ts @@ -277,9 +277,7 @@ export function* eachPatternOperand(pattern: Pattern): Iterable { case "ObjectPattern": { for (const property of pattern.properties) { if (property.kind === "ObjectProperty") { - if (property.place.kind === "Identifier") { - yield property.place; - } + yield property.place; } else if (property.kind === "Spread") { yield property.place; } else {