diff options
author | James Lopez <james@jameslopez.es> | 2016-06-15 18:31:00 +0300 |
---|---|---|
committer | James Lopez <james@jameslopez.es> | 2016-06-15 18:31:00 +0300 |
commit | 4bde59341f6d4679b2eefa2c5e332c33c3c76050 (patch) | |
tree | d9c98b030da720f0d413f6ad5e3066cb67559fdd /app/services/projects | |
parent | f6896f9381b9d833e0db4d0e5be95f2ffc64561a (diff) |
lots of refactoring again based on feedback. Changed the UI slightly and also fixed a small bug
Diffstat (limited to 'app/services/projects')
-rw-r--r-- | app/services/projects/create_service.rb | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/app/services/projects/create_service.rb b/app/services/projects/create_service.rb index ffac357e91d..55956be2844 100644 --- a/app/services/projects/create_service.rb +++ b/app/services/projects/create_service.rb @@ -54,7 +54,7 @@ module Projects @project.import_start if @project.import? - after_create_actions if @project.persisted? && !@project.gitlab_project_import? + after_create_actions if @project.persisted? if @project.errors.empty? @project.add_import_job if @project.import? @@ -80,16 +80,18 @@ module Projects def after_create_actions log_info("#{@project.owner.name} created a new project \"#{@project.name_with_namespace}\"") - @project.create_wiki if @project.wiki_enabled? + unless @project.gitlab_project_import? + @project.create_wiki if @project.wiki_enabled? - @project.build_missing_services + @project.build_missing_services - @project.create_labels + @project.create_labels + end event_service.create_project(@project, current_user) system_hook_service.execute_hooks_for(@project, :create) - unless @project.group + unless @project.group || @project.gitlab_project_import? @project.team << [current_user, :master, current_user] end end |