Support Unicode characters in filenames, both in source filenames and in the names of proxied paths. Fixes #332.
This commit is contained in:
parent
23e0586896
commit
dddd409336
9 changed files with 46 additions and 13 deletions
|
@ -29,7 +29,8 @@ module Middleman
|
|||
# @param [String] path
|
||||
# @return [String]
|
||||
def self.normalize_path(path)
|
||||
path.sub(/^\//, "").gsub("%20", " ")
|
||||
# The tr call works around a bug in Ruby's Unicode handling
|
||||
path.sub(/^\//, "").tr('','')
|
||||
end
|
||||
|
||||
# Extract the text of a Rack response as a string.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue