| 1 | <?php |
||
| 17 | class User extends \yii\web\User |
||
| 18 | { |
||
| 19 | /** |
||
| 20 | * @var string the seller login |
||
| 21 | */ |
||
| 22 | public $seller; |
||
| 23 | |||
| 24 | public function init() |
||
| 31 | |||
| 32 | public function not($key) |
||
| 41 | |||
| 42 | public function is($key) |
||
| 51 | /** |
||
| 52 | * @inheritdoc |
||
| 53 | * XXX fixes redirect loop when identity is set but the object is empty |
||
| 54 | * @return bool |
||
| 55 | */ |
||
| 56 | public function getIsGuest() |
||
| 60 | } |
||
| 61 |
If an expression can have both
false, andnullas possible values. It is generally a good practice to always use strict comparison to clearly distinguish between those two values.