Closes Ticket #4.

Now, when non-string values are passed into an attribute hash for a tag, they will have #to_s called on them, and then be in the proper 
format.

ALL numeric values are also put in quotes.




git-svn-id: svn://hamptoncatlin.com/haml/trunk@11 7063305b-7217-0410-af8c-cdc13e5119b9
This commit is contained in:
hcatlin 2006-07-26 15:45:09 +00:00
parent 5b1819d977
commit 782a199d5d
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ module HAML
def build_attributes(attributes = {}) def build_attributes(attributes = {})
return "" if attributes.empty? return "" if attributes.empty?
" " + (attributes.collect { |attr_name, val| attr_name.to_s + "='" + val + "'" }).join(" ") " " + (attributes.collect { |attr_name, val| attr_name.to_s + "='" + val.to_s + "'" }).join(" ")
end end
def close_tag def close_tag