From 2fd47a0e95da2ef2dada1012f09d6c0d1b7431a9 Mon Sep 17 00:00:00 2001 From: Douwe Maan Date: Tue, 21 Apr 2015 15:01:48 +0200 Subject: Don't attempt to move if original path only contains periods. --- db/migrate/20150421120000_remove_periods_at_ends_of_usernames.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'db') diff --git a/db/migrate/20150421120000_remove_periods_at_ends_of_usernames.rb b/db/migrate/20150421120000_remove_periods_at_ends_of_usernames.rb index e2f231ba709..01ea199d618 100644 --- a/db/migrate/20150421120000_remove_periods_at_ends_of_usernames.rb +++ b/db/migrate/20150421120000_remove_periods_at_ends_of_usernames.rb @@ -54,6 +54,9 @@ class RemovePeriodsAtEndsOfUsernames < ActiveRecord::Migration end changed_paths.each do |path_was, path| + # Don't attempt to move if original path only contains periods. + next if path_was =~ /\A\.+\z/ + if gitlab_shell.mv_namespace(path_was, path) # If repositories moved successfully we need to remove old satellites # and send update instructions to users. -- cgit v1.2.3