clean_path should drop all leading dashes, not just one

This commit is contained in:
J. Daniel Schmidt 2015-04-08 15:53:07 +02:00
parent 706be56317
commit d03cec0e69
1 changed files with 1 additions and 1 deletions

View File

@ -61,7 +61,7 @@ class Namespace < ActiveRecord::Base
def clean_path(path)
path.gsub!(/@.*\z/, "")
path.gsub!(/\.git\z/, "")
path.gsub!(/\A-/, "")
path.gsub!(/\A-+/, "")
path.gsub!(/\.+\z/, "")
path.gsub!(/[^a-zA-Z0-9_\-\.]/, "")