Permalink
Browse files

strings for keys instead of symbols

  • Loading branch information...
1 parent e83836c commit e5506b534c2f380e853b4f77acd365e727513d96 @jtimberman jtimberman committed Apr 13, 2012
Showing with 7 additions and 7 deletions.
  1. +3 −3 attributes/default.rb
  2. +4 −4 templates/default/resolv.conf.erb
View
@@ -1,3 +1,3 @@
-default[:resolver][:search] = domain
-default[:resolver][:nameservers] = []
-default[:resolver][:options] = {}
+default['resolver']['search'] = domain
+default['resolver']['nameservers'] = []
+default['resolver']['options'] = {}
@@ -1,7 +1,7 @@
-search <%= node[:resolver][:search] %>
-<% node[:resolver][:nameservers].each do |nameserver| -%>
+search <%= node['resolver']['search'] %>
+<% node['resolver']['nameservers'].each do |nameserver| -%>
nameserver <%= nameserver %>
<% end %>
-<% if ! node[:resolver][:options].empty? -%>
-options <%= node[:resolver][:options].map { |opt, val| val ? "#{opt}:#{val}" : opt }.sort.join(" ") %>
+<% unless ['resolver']['options'].empty? -%>
+options <%= node['resolver']['options'].map { |opt, val| val ? "#{opt}:#{val}" : opt }.sort.join(" ") %>
<% end -%>

3 comments on commit e5506b5

Contributor

josephholsten replied Apr 14, 2012

Any particular reason?

Contributor

mattray replied Apr 15, 2012

Here's jtimberman's previous explanation in the foodcritic wiki
acrmp/foodcritic#1

Contributor

josephholsten replied Apr 15, 2012

Awesome, I've been meaning to check out food critic. I'll keep an eye out for these elsewhere. Thanks for the snappy response!

Please sign in to comment.