summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2017-06-23 18:44:49 +0000
committerkushalpandya <kushal@gitlab.com>2017-06-26 11:11:18 +0530
commit55e4987f7013d43a4022aac5d71c19c8cb86c9e2 (patch)
treef49c0eaa6c143f5d3875c10e6a74f37f3d54fdad /app
parent97faced4f40999107ab72a526790dc3ce89b23c3 (diff)
downloadgitlab-ce-55e4987f7013d43a4022aac5d71c19c8cb86c9e2.tar.gz
Merge branch 'mk-fix-issue-34068' into 'master'
Fix 500 on failure to create a private group Closes #34068 See merge request !12394
Diffstat (limited to 'app')
-rw-r--r--app/views/layouts/header/_new_dropdown.haml4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/views/layouts/header/_new_dropdown.haml b/app/views/layouts/header/_new_dropdown.haml
index c7302414386..969c423b032 100644
--- a/app/views/layouts/header/_new_dropdown.haml
+++ b/app/views/layouts/header/_new_dropdown.haml
@@ -4,7 +4,7 @@
= icon('caret-down')
.dropdown-menu-nav.dropdown-menu-align-right
%ul
- - if @group
+ - if @group&.persisted?
- create_group_project = can?(current_user, :create_projects, @group)
- create_group_subgroup = can?(current_user, :create_subgroup, @group)
- if create_group_project || create_group_subgroup
@@ -18,7 +18,7 @@
%li.divider
%li.dropdown-bold-header GitLab
- - if @project && @project.persisted?
+ - if @project&.persisted?
- create_project_issue = can?(current_user, :create_issue, @project)
- merge_project = can?(current_user, :create_merge_request, @project) ? @project : (current_user && current_user.fork_of(@project))
- create_project_snippet = can?(current_user, :create_project_snippet, @project)