Fixed route compile never fully coercing to String

This commit is contained in:
Bob Aman 2009-05-01 10:44:24 -04:00 committed by Ryan Tomayko
parent d5a4d472c4
commit 0a6927cad0
1 changed files with 1 additions and 1 deletions

View File

@ -794,7 +794,7 @@ module Sinatra
if path.respond_to? :to_str
special_chars = %w{. + ( )}
pattern =
path.gsub(/((:\w+)|[\*#{special_chars.join}])/) do |match|
path.to_str.gsub(/((:\w+)|[\*#{special_chars.join}])/) do |match|
case match
when "*"
keys << 'splat'