Permalink
Browse files

to_s on values

  • Loading branch information...
1 parent 459c97b commit 47c81c443734019a136fd81dafb800416ff31d89 Orion Henry committed Oct 25, 2010
Showing with 3 additions and 5 deletions.
  1. +1 −1 VERSION
  2. +2 −4 lib/json2env.rb
View
@@ -1 +1 @@
-0.0.2
+0.0.3
View
@@ -18,10 +18,8 @@ def create
end
Dir.mkdir(dir)
@env.each do |key, value|
- if value
- File.open("#{dir}/#{key}", "w") do |file|
- file.write(value.gsub(/\r\n|\r|\n/, "\0"))
- end
+ File.open("#{dir}/#{key}", "w") do |file|
+ file.write(value.to_s.gsub(/\r\n|\r|\n/, "\0"))
end
end
end

0 comments on commit 47c81c4

Please sign in to comment.