Skip to content

Commit

Permalink
fix(install): handle possible null while changing fields
Browse files Browse the repository at this point in the history
  • Loading branch information
btry committed Oct 21, 2022
1 parent 275c350 commit 0a847af
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions install/upgrade_to_2.13.php
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,16 @@ public function fixTables(): void {
['ola_rule' => '0'],
['ola_rule' => null]
);
$DB->update(
$table,
['tag_questions' => ''],
['tag_questions' => null]
);
$DB->update(
$table,
['tag_specifics' => ''],
['tag_specifics' => null]
);
$this->migration->changeField($table, 'validation_followup', 'validation_followup', 'bool', ['after' => 'urgency_question', 'value' => '1']);
$this->migration->changeField($table, 'destination_entity', 'destination_entity', 'integer', ['after' => 'validation_followup', 'value' => '1']);
$this->migration->changeField($table, 'destination_entity_value', 'destination_entity_value', $unsignedIntType, ['after' => 'destination_entity', 'default' => '1']);
Expand Down

0 comments on commit 0a847af

Please sign in to comment.