lib/nilac/compile_case_statement.rb in nilac-0.0.4.3.9.6 vs lib/nilac/compile_case_statement.rb in nilac-0.0.4.3.9.7
- old
+ new
@@ -89,10 +89,10 @@
end
when_statements_index = when_statements_index.flatten
- if replace_strings(statement_block.join).include?("else\n")
+ if replace_strings(statement_block.join).include?("else\n") or replace_strings(statement_block.join).include?("else\r\n")
else_statement = statement_block.reject {|element| !replace_strings(element).strip.eql?("else")}
else_block = statement_block[statement_block.index(else_statement[0])+1...-1]
\ No newline at end of file