Skip to content

Commit 95b2584

Browse files
committed
Fix incorrect logic in forced_brace_bounds? translation
1 parent f5ac5fe commit 95b2584

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/syntax_tree/node.rb

+3-1
Original file line numberDiff line numberDiff line change
@@ -2059,8 +2059,10 @@ def forced_brace_bounds?(q)
20592059
when If, IfMod, IfOp, Unless, UnlessMod, While, WhileMod, Until,
20602060
UntilMod
20612061
return true if parent.predicate == previous
2062-
previous = parent
20632062
end
2063+
2064+
previous = parent
2065+
false
20642066
end
20652067
end
20662068

0 commit comments

Comments
 (0)