From 3e9242764726180db6457bbec704e51508b902ca Mon Sep 17 00:00:00 2001 From: nex3 Date: Wed, 2 Jan 2008 18:57:39 +0000 Subject: [PATCH] Fixing a bug caused by the last checkin. Thanks to Xin from the Haml list for pointing this out. git-svn-id: svn://hamptoncatlin.com/haml/trunk@707 7063305b-7217-0410-af8c-cdc13e5119b9 --- lib/haml/precompiler.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/haml/precompiler.rb b/lib/haml/precompiler.rb index ef4ec2c1..3c9fd16b 100644 --- a/lib/haml/precompiler.rb +++ b/lib/haml/precompiler.rb @@ -643,7 +643,7 @@ END # Counts the tabulation of a line. def count_soft_tabs(line) - spaces = line.index(/[^ ]/) + spaces = line.index(/([^ ]|$)/) if line[spaces] == ?\t return nil if line.strip.empty? raise SyntaxError.new("Illegal Indentation: Only two space characters are allowed as tabulation.")