Ensure old namespace directory exists before moving it
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
This commit is contained in:
parent
ce47dd4bb0
commit
d044c14290
1 changed files with 3 additions and 0 deletions
|
@ -114,6 +114,9 @@ class Namespace < ActiveRecord::Base
|
||||||
end
|
end
|
||||||
|
|
||||||
def move_dir
|
def move_dir
|
||||||
|
# Ensure old directory exists before moving it
|
||||||
|
gitlab_shell.add_namespace(path_was)
|
||||||
|
|
||||||
if gitlab_shell.mv_namespace(path_was, path)
|
if gitlab_shell.mv_namespace(path_was, path)
|
||||||
# If repositories moved successfully we need to
|
# If repositories moved successfully we need to
|
||||||
# send update instructions to users.
|
# send update instructions to users.
|
||||||
|
|
Loading…
Reference in a new issue