Browse files

use erb for wardaround of Sinatra's (Tilt's) encoding handling. :<

  • Loading branch information...
1 parent 0b3b6f6 commit 866a9ea35356f3c9e1969344b481efb8ed6de85b @kou kou committed Dec 22, 2010
Showing with 2 additions and 5 deletions.
  1. +1 −5 app.rb
  2. +1 −0 views/prefix.erb
View
6 app.rb
@@ -35,11 +35,7 @@ def jigoku?
end
def prefix
- if jigoku?
- "地獄の".force_encoding("ascii-8bit")
- else
- ""
- end
+ erb(:prefix).force_encoding("ascii-8bit")
end
def description
View
1 views/prefix.erb
@@ -0,0 +1 @@
+<% if jigoku? -%>地獄の<% end -%>

0 comments on commit 866a9ea

Please sign in to comment.