Conditions | 1 |
Paths | 1 |
Total Lines | 40 |
Code Lines | 17 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
10 | public function up() |
||
11 | { |
||
12 | $playersTable = $this->table('players'); |
||
13 | $playersTable |
||
14 | ->changeColumn('avatar', 'string', [ |
||
15 | 'limit' => 200, |
||
16 | 'null' => true, |
||
17 | 'comment' => "The path to the player's avatar relative to the bzion project root", |
||
18 | ]) |
||
19 | ->update() |
||
20 | ; |
||
21 | |||
22 | $this->execute(" |
||
23 | UPDATE |
||
24 | players |
||
25 | SET |
||
26 | avatar = NULL |
||
27 | WHERE |
||
28 | status IN ('deleted', 'disabled') |
||
29 | "); |
||
30 | |||
31 | $teamsTable = $this->table('teams'); |
||
32 | $teamsTable |
||
33 | ->changeColumn('avatar', 'string', [ |
||
34 | 'limit' => 200, |
||
35 | 'null' => true, |
||
36 | 'comment' => "The path to the player's avatar relative to the bzion project root", |
||
37 | ]) |
||
38 | ->update() |
||
39 | ; |
||
40 | |||
41 | $this->execute(" |
||
42 | UPDATE |
||
43 | teams |
||
44 | SET |
||
45 | avatar = NULL |
||
46 | WHERE |
||
47 | status IN ('deleted', 'disabled') |
||
48 | "); |
||
49 | } |
||
50 | } |
||
51 |