allow underscore and dash in subdomains

This commit is contained in:
Konstantin Haase 2012-10-18 23:49:15 +02:00
parent 6252deadee
commit 720cbef577

View File

@ -223,8 +223,8 @@ class Travis::Api::App
def target_ok?(target_origin)
target_origin =~ %r{
^ http:// (localhost|127\.0\.0\.1)(:\d+)? $ |
^ https:// (\w+\.)?travis-ci\.(org|com) $
^ http:// (localhost|127\.0\.0\.1)(:\d+)? $ |
^ https:// ([\w-_]+\.)?travis-ci\.(org|com) $
}x
end
end