diff options
author | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2016-03-17 23:39:56 +0300 |
---|---|---|
committer | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2016-03-18 02:55:59 +0300 |
commit | 7ee528336ad86e478b6db6d0039aec607c8f0192 (patch) | |
tree | 21c099c1de7ce28fe3c3fb81b2d832cb5653e19b /app/services/projects/autocomplete_service.rb | |
parent | 43d8bdb4f048cbeb5675ed9120cb1aeb415b9586 (diff) |
Restrict access for confidential issues on autocomplete
Diffstat (limited to 'app/services/projects/autocomplete_service.rb')
-rw-r--r-- | app/services/projects/autocomplete_service.rb | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/app/services/projects/autocomplete_service.rb b/app/services/projects/autocomplete_service.rb index 7408e09ed1e..ba50305dbd5 100644 --- a/app/services/projects/autocomplete_service.rb +++ b/app/services/projects/autocomplete_service.rb @@ -1,11 +1,7 @@ module Projects class AutocompleteService < BaseService - def initialize(project) - @project = project - end - def issues - @project.issues.opened.select([:iid, :title]) + @project.issues.visible_to_user(current_user).opened.select([:iid, :title]) end def merge_requests |