Hi all,
Just thought I'd drop you a line to see what you thought about an
issue that bugged me a little this afternoon while trying to use Haml
(1.7.0, standalone) to build a website.
The issue I ran into was that this line fails:
Haml::Engine.new(tpl, {:filters => {:multimarkdown =>
MultiMarkdown}})
This line, however, works just fine (notice string key in filters
hash):
Haml::Engine.new(tpl, {:filters => {'multimarkdown' =>
MultiMarkdown}})
I would say that without going all HashWithIndifferentAccess on your
asses ... it's ugly and I know it, it would be a bit more PoLS-
friendly[1] if we could just have this diff applied to Haml:
--- engine.rb.old 2007-08-09 00:35:26.000000000 +0100
+++ engine.rb 2007-08-09 00:35:52.000000000 +0100
@@ -334,7 +334,7 @@
end
when FILTER
name = line[1..-1].downcase
- start_filtered(options[:filters][name.to_s] || name)
+ start_filtered(options[:filters][name.to_s] ||
options[:filters][name.to_sym] || name)
when DOCTYPE
if line[0...3] == '!!!'
render_doctype(line)
Regards, in the hope that this might just save someone else a
headache,
Nick
[1]: Matz's Principle of Least Surprise
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Haml" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/haml?hl=en
-~----------~----~----~----~------~----~------~--~---