Conditions | 2 |
Paths | 2 |
Total Lines | 15 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 2.003 |
Changes | 0 |
1 | <?php |
||
22 | 1 | public function up() |
|
23 | { |
||
24 | 1 | $tableOptions = null; |
|
25 | 1 | if ($this->db->driverName === 'mysql') { |
|
26 | // http://stackoverflow.com/questions/766809/whats-the-difference-between-utf8-general-ci-and-utf8-unicode-ci |
||
27 | $tableOptions = 'CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE=InnoDB'; |
||
28 | } |
||
29 | |||
30 | 1 | $this->createTable('{{%session}}', [ |
|
31 | 1 | 'id' => $this->string()->notNull(), |
|
32 | 1 | 'expire' => $this->integer(), |
|
33 | 1 | 'data' => $this->binary(), |
|
34 | 1 | 'PRIMARY KEY ([[id]])', |
|
35 | 1 | ], $tableOptions); |
|
36 | 1 | } |
|
37 | |||
46 |