| Conditions | 1 |
| Paths | 1 |
| Total Lines | 31 |
| Code Lines | 16 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 13 | public function change() |
||
| 14 | { |
||
| 15 | /** |
||
| 16 | * users |
||
| 17 | */ |
||
| 18 | $users = $this->table('users', ['collation' => 'utf8mb4_unicode_ci']); |
||
| 19 | |||
| 20 | $users->addColumn('email', 'string', ['length' => 128]); |
||
| 21 | $users->addColumn('password_hash', 'string', ['length' => 255]); |
||
| 22 | $users->addColumn('modified', 'datetime'); |
||
| 23 | $users->addColumn('created', 'datetime'); |
||
| 24 | |||
| 25 | $users->create(); |
||
| 26 | |||
| 27 | $users->changeColumn('id', 'integer', ['signed' => false, 'identity' => true]); |
||
| 28 | $users->update(); |
||
| 29 | |||
| 30 | /** |
||
| 31 | * user_password_resets |
||
| 32 | */ |
||
| 33 | $users = $this->table('user_password_resets', ['collation' => 'utf8mb4_unicode_ci']); |
||
| 34 | |||
| 35 | $users->addColumn('user_id', 'integer', ['signed' => false]); |
||
| 36 | $users->addColumn('token_hash', 'string', ['length' => 255]); |
||
| 37 | $users->addColumn('created', 'datetime'); |
||
| 38 | |||
| 39 | $users->create(); |
||
| 40 | |||
| 41 | $users->changeColumn('id', 'integer', ['signed' => false, 'identity' => true]); |
||
| 42 | $users->update(); |
||
| 43 | } |
||
| 44 | } |
||
| 45 |
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.