| Conditions | 2 |
| Paths | 2 |
| Total Lines | 9 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 36 | private function random_str($length, $keyspace = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ') |
||
| 37 | { |
||
| 38 | $str = ''; |
||
| 39 | $max = mb_strlen($keyspace, '8bit') - 1; |
||
| 40 | for ($i = 0; $i < $length; ++$i) { |
||
| 41 | $str .= $keyspace[rand(0, $max)]; |
||
| 42 | } |
||
| 43 | return $str; |
||
| 44 | } |
||
| 45 | public function getApiEndPoint() |
||
| 67 |
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.