Conditions | 3 |
Paths | 2 |
Total Lines | 6 |
Code Lines | 3 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
25 | public function __construct(array $values) |
||
26 | { |
||
27 | if (!isset($values['value']) && !isset($values['name'])) { |
||
28 | throw new \BadMethodCallException('The @Right annotation must be passed a right name. For instance: "@Right(\'my_right\')"'); |
||
29 | } |
||
30 | $this->name = $values['value'] ?? $values['name']; |
||
31 | } |
||
41 |