summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2017-05-24 12:56:05 +0100
committerPhil Hughes <me@iamphill.com>2017-05-24 12:56:05 +0100
commitfd3750c68590119d0cfb48c8b5245f6c09cc9f02 (patch)
treea2c0f80613363c821a495f7f3f516b2ad691926a
parenta9470c45e42369235b5a6f5082b3a2a34bfb3f71 (diff)
downloadgitlab-ce-fd3750c68590119d0cfb48c8b5245f6c09cc9f02.tar.gz
fixed bug with can? check when user is not logged in
-rw-r--r--app/helpers/issuables_helper.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/helpers/issuables_helper.rb b/app/helpers/issuables_helper.rb
index fb73c92279d..62b1bfa997e 100644
--- a/app/helpers/issuables_helper.rb
+++ b/app/helpers/issuables_helper.rb
@@ -204,7 +204,7 @@ module IssuablesHelper
endpoint: namespace_project_issue_path(@project.namespace, @project, issuable),
canUpdate: can?(current_user, :update_issue, issuable),
canDestroy: can?(current_user, :destroy_issue, issuable),
- canMove: issuable.can_move?(current_user),
+ canMove: current_user ? issuable.can_move?(current_user) : false,
issuableRef: issuable.to_reference,
isConfidential: issuable.confidential,
markdownPreviewUrl: preview_markdown_path(@project),