We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ 119-128 (lines=10) @@ | ||
116 | ); |
|
117 | } |
|
118 | ||
119 | private function fieldComplexity(Node $node, $complexity = 0) |
|
120 | { |
|
121 | if (isset($node->selectionSet)) { |
|
122 | foreach ($node->selectionSet->selections as $childNode) { |
|
123 | $complexity = $this->nodeComplexity($childNode, $complexity); |
|
124 | } |
|
125 | } |
|
126 | ||
127 | return $complexity; |
|
128 | } |
|
129 | ||
130 | private function nodeComplexity(Node $node, $complexity = 0) |
|
131 | { |
@@ 80-89 (lines=10) @@ | ||
77 | return $this->getMaxQueryDepth() !== static::DISABLED; |
|
78 | } |
|
79 | ||
80 | private function fieldDepth(Node $node, $depth = 0, $maxDepth = 0) |
|
81 | { |
|
82 | if (isset($node->selectionSet)) { |
|
83 | foreach ($node->selectionSet->selections as $childNode) { |
|
84 | $maxDepth = $this->nodeDepth($childNode, $depth, $maxDepth); |
|
85 | } |
|
86 | } |
|
87 | ||
88 | return $maxDepth; |
|
89 | } |
|
90 | ||
91 | private function nodeDepth(Node $node, $depth = 0, $maxDepth = 0) |
|
92 | { |