Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
967762f7
Commit
967762f7
authored
Aug 06, 2020
by
Sean Arnold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move resolver_complexity method to module
parent
a3e72ac4
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
7 deletions
+9
-7
app/graphql/resolvers/concerns/issue_resolver_fields.rb
app/graphql/resolvers/concerns/issue_resolver_fields.rb
+9
-0
app/graphql/resolvers/issues_resolver.rb
app/graphql/resolvers/issues_resolver.rb
+0
-7
No files found.
app/graphql/resolvers/concerns/issue_resolver_fields.rb
View file @
967762f7
...
...
@@ -48,4 +48,13 @@ module IssueResolverFields
description:
'Filter issues by the given issue types'
,
required:
false
end
class_methods
do
def
resolver_complexity
(
args
,
child_complexity
:)
complexity
=
super
complexity
+=
2
if
args
[
:labelName
]
complexity
end
end
end
app/graphql/resolvers/issues_resolver.rb
View file @
967762f7
...
...
@@ -42,13 +42,6 @@ module Resolvers
end
end
def
self
.
resolver_complexity
(
args
,
child_complexity
:)
complexity
=
super
complexity
+=
2
if
args
[
:labelName
]
complexity
end
def
non_stable_cursor_sort?
(
sort
)
NON_STABLE_CURSOR_SORTS
.
include?
(
sort
)
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment