Conditions | 4 |
Paths | 4 |
Total Lines | 16 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
45 | public function belongsToUserAndIsNotExpired($attribute, $params) |
||
46 | { |
||
47 | if (!$this->hasErrors()) { |
||
48 | $code = Code::find()->where([ |
||
49 | 'hash' => hash('sha256', $this->activation_code . '_activation_token') |
||
50 | ])->one(); |
||
51 | |||
52 | if ($code === null) { |
||
53 | $this->addError('activation_code', Yii::t('yrc', 'The activation code provided is not valid.')); |
||
54 | return; |
||
55 | } |
||
56 | |||
57 | $this->user = Yii::$app->user->identityClass::find()->where(['id' => $code->user_id])->one(); |
||
58 | |||
59 | if ($this->user === null) { |
||
60 | $this->addError('activation_code', Yii::t('yrc', 'The activation code provided is not valid.')); |
||
61 | } |
||
82 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths