Commit 51a952ae authored by Igor Drozdov's avatar Igor Drozdov

Fix 2.7 warnings by extracting kwargs

When arguments are aggregated using *args, the kwargs
are represented as a hash. Let's use **kwargs to separate
them from args
parent e3aef48b
...@@ -79,7 +79,7 @@ module EE ...@@ -79,7 +79,7 @@ module EE
super.preload(:blocking_merge_requests) super.preload(:blocking_merge_requests)
end end
def sort_by_attribute(method, *args) def sort_by_attribute(method, *args, **kwargs)
if method.to_s == 'review_time_desc' if method.to_s == 'review_time_desc'
order_review_time_desc order_review_time_desc
else else
......
...@@ -3,8 +3,8 @@ ...@@ -3,8 +3,8 @@
module API module API
module Helpers module Helpers
module Pagination module Pagination
def paginate(*args) def paginate(*args, **kwargs)
Gitlab::Pagination::OffsetPagination.new(self).paginate(*args) Gitlab::Pagination::OffsetPagination.new(self).paginate(*args, **kwargs)
end end
end end
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment