| Conditions | 2 |
| Paths | 2 |
| Total Lines | 15 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 26 | public function run() |
||
| 27 | { |
||
| 28 | DB::statement('SET FOREIGN_KEY_CHECKS=0;'); |
||
| 29 | DB::table(config('rinvex.fort.tables.users'))->truncate(); |
||
| 30 | |||
| 31 | // Get users data |
||
| 32 | $users = require __DIR__.'/../../resources/data/users.php'; |
||
| 33 | |||
| 34 | // Create new users |
||
| 35 | foreach ($users as $user) { |
||
| 36 | app('rinvex.fort.user')->create($user); |
||
| 37 | } |
||
| 38 | |||
| 39 | DB::statement('SET FOREIGN_KEY_CHECKS=1;'); |
||
| 40 | } |
||
| 41 | } |
||
| 42 |
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.