Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 7 |
Lines | 14 |
Ratio | 100 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
31 | View Code Duplication | public function toArray() |
|
32 | { |
||
33 | $rolesCollection = $this->getAdminRolesCollection(); |
||
34 | $rolesArray = array(); |
||
35 | |||
36 | foreach ($rolesCollection as $role) { |
||
37 | /** @var Mage_Admin_Model_Role $role */ |
||
38 | $rolesArray[] = array( |
||
39 | $role->getRoleName() => $role->getRoleName(), |
||
40 | ); |
||
41 | } |
||
42 | |||
43 | return $rolesArray; |
||
44 | } |
||
45 | |||
55 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.