BUGFIX - in domain name not captured by route

This commit is contained in:
Sam 2014-05-29 09:31:17 +10:00
parent 6be3dcb8e3
commit 6d88d7a290

View File

@ -213,7 +213,7 @@ Discourse::Application.routes.draw do
post "user_avatar/:username/refresh_gravatar" => "user_avatars#refresh_gravatar"
get "user_avatar/:hostname/:username/:size/:version.png" => "user_avatars#show",
format: false, constraints: {hostname: /[\w\.]+/}
format: false, constraints: {hostname: /[\w\.-]+/}
get "uploads/:site/:id/:sha.:extension" => "uploads#show", constraints: {site: /\w+/, id: /\d+/, sha: /[a-z0-9]{15,16}/i, extension: /\w{2,}/}