Grammar::compileAllowFiltering()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 2
nc 2
nop 2
crap 2
1
<?php
2
3
namespace lroman242\LaravelCassandra\Query;
4
5
use Illuminate\Database\Query\Grammars\Grammar as BaseGrammar;
6
7
class Grammar extends BaseGrammar
8
{
9
    /**
10
     * The components that make up a select clause.
11
     *
12
     * @var array
13
     */
14
    protected $selectComponents = [
15
        'aggregate',
16
        'columns',
17
        'from',
18
        'wheres',
19
        'orders',
20
        'limit',
21
        'groups',
22
        'allowFiltering'
23
    ];
24
25 56
    public function compileAllowFiltering(Builder $query, $bool)
0 ignored issues
show
Unused Code introduced by
The parameter $query is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
26
    {
27 56
        return (bool) $bool ? 'ALLOW FILTERING' : '';
28
    }
29
}
30