From 5bb80a58666eca6984eb2650ccd2cee1992b3347 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9my=20Coutable?= Date: Thu, 27 Jun 2019 18:48:26 +0200 Subject: Ensure the Insights configuration project is part of the group and is accessible to the current user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Rémy Coutable --- ee/lib/gitlab/insights/finders/issuable_finder.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ee/lib') diff --git a/ee/lib/gitlab/insights/finders/issuable_finder.rb b/ee/lib/gitlab/insights/finders/issuable_finder.rb index 55b1c9623e0..1ed154376b7 100644 --- a/ee/lib/gitlab/insights/finders/issuable_finder.rb +++ b/ee/lib/gitlab/insights/finders/issuable_finder.rb @@ -54,7 +54,7 @@ module Gitlab attr_reader :entity, :current_user, :opts def finder - issuable_type = opts[:issuable_type].to_sym + issuable_type = opts[:issuable_type]&.to_sym FINDERS[issuable_type] || raise(InvalidIssuableTypeError, "Invalid `:issuable_type` option: `#{opts[:issuable_type]}`. Allowed values are #{FINDERS.keys}!") -- cgit v1.2.1