Skip to content

Commit ce1768d

Browse files
committed
Update method_compiler.rb
1 parent b740324 commit ce1768d

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

lib/phlex/compiler/method_compiler.rb

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,7 @@ def around_visit(node)
2222

2323
# We want to clear the buffer when there’s a node that isn’t a statements node,
2424
# but we should ignore nils, which are usually other buffers.
25-
if result
26-
unless Refract::StatementsNode === result
27-
clear_buffer
28-
end
29-
end
25+
clear_buffer unless result in Refract::StatementsNode | nil
3026

3127
result
3228
end

0 commit comments

Comments
 (0)