GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( 951ad1...29ba67 )
by Alexey
08:55
created

FacetModificationPropertyIterator::getCriteria()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 13
Code Lines 9

Duplication

Lines 13
Ratio 100 %

Code Coverage

Tests 9
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 13
loc 13
ccs 9
cts 9
cp 1
rs 9.4285
cc 2
eloc 9
nc 2
nop 1
crap 2
1
<?php
2
/**
3
 * @author Alexey Tatarinov <[email protected]>
4
 * @link https://github.com/shogodev/argilla/
5
 * @copyright Copyright &copy; 2003-2016 Shogo
6
 * @license http://argilla.ru/LICENSE
7
 */
8
class FacetModificationPropertyIterator extends FacetPropertyIterator
9
{
10 4 View Code Duplication
  protected function getCriteria($productIdList)
0 ignored issues
show
Duplication introduced by
This method seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
11
  {
12 4
    $criteria = new CDbCriteria();
13 4
    $criteria->select = CMap::mergeArray(array('t.id'), $this->propertyList);
14 4
    $criteria->distinct = true;
15 4
    $criteria->join = 'JOIN '.Yii::app()->db->schema->quoteTableName($this->assignmentTable).' AS a ON a.product_id = t.parent';
16 4
    $criteria->addCondition('NOT t.parent IS NULL');
17
18 4
    if( !is_null($productIdList) )
19 4
      $criteria->addInCondition('t.id', $productIdList);
20
21 4
    return $criteria;
22
  }
23
}