diff options
author | Patrick Derichs <pderichs@gitlab.com> | 2019-06-15 07:19:54 +0200 |
---|---|---|
committer | Patrick Derichs <pderichs@gitlab.com> | 2019-06-19 10:56:55 +0200 |
commit | b5b5658868a8aaac0dc340f6d7c9a14842cab2e5 (patch) | |
tree | b2ef2a019e3658e2dec322966241a83197d61aad /app/finders | |
parent | 932a9a0c77a02e1d948f45cffe5e936e915ae0bc (diff) | |
download | gitlab-ce-b5b5658868a8aaac0dc340f6d7c9a14842cab2e5.tar.gz |
Separate conditions to increase readability
Diffstat (limited to 'app/finders')
-rw-r--r-- | app/finders/notes_finder.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/finders/notes_finder.rb b/app/finders/notes_finder.rb index 83bf015488f..06d01245e90 100644 --- a/app/finders/notes_finder.rb +++ b/app/finders/notes_finder.rb @@ -36,7 +36,8 @@ class NotesFinder target_id = @params[:target_id] target_iid = @params[:target_iid] - return @target = nil unless target_type && (target_id || target_iid) + return @target = nil unless target_type + return @target = nil unless (target_id || target_iid) @target = if target_type == "commit" |