summaryrefslogtreecommitdiff
path: root/app/finders
diff options
context:
space:
mode:
authorHeinrich Lee Yu <hleeyu@gmail.com>2018-10-27 23:52:26 +0800
committerHeinrich Lee Yu <hleeyu@gmail.com>2018-11-01 07:45:36 +0800
commit8df7e6021b0da30e3b7550ca83cd9ab3f991c235 (patch)
tree3405c6855ff3b1b78d488be8d041ea2b1ab19005 /app/finders
parent69dcab2311e84b1a12cefab2cd92ef37ff97e38f (diff)
downloadgitlab-ce-8df7e6021b0da30e3b7550ca83cd9ab3f991c235.tar.gz
Fix tests
Diffstat (limited to 'app/finders')
-rw-r--r--app/finders/issuable_finder.rb15
1 files changed, 8 insertions, 7 deletions
diff --git a/app/finders/issuable_finder.rb b/app/finders/issuable_finder.rb
index 27a850b2603..baa3e0853eb 100644
--- a/app/finders/issuable_finder.rb
+++ b/app/finders/issuable_finder.rb
@@ -480,13 +480,14 @@ class IssuableFinder
def by_my_reaction_emoji(items)
if params[:my_reaction_emoji].present? && current_user
- if filter_by_no_reaction?
- items = items.not_awarded(current_user)
- elsif filter_by_any_reaction?
- items = items.awarded_any(current_user)
- else
- items = items.awarded(current_user, params[:my_reaction_emoji])
- end
+ items =
+ if filter_by_no_reaction?
+ items.not_awarded(current_user)
+ elsif filter_by_any_reaction?
+ items.awarded(current_user)
+ else
+ items.awarded(current_user, params[:my_reaction_emoji])
+ end
end
items