Skip to content

Commit 3af0b01

Browse files
authored
Merge pull request #73 from LibreCodeCoop/fix/issue-58-active-bool-compat
fix(migration): support false on active boolean column
2 parents 5d7e619 + d374f1e commit 3af0b01

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

lib/Migration/Version1001Date20260404010000.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,15 @@ class Version1001Date20260404010000 extends SimpleMigrationStep {
2424
public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper {
2525
/** @var ISchemaWrapper $schema */
2626
$schema = $schemaClosure();
27+
28+
if (!$schema->hasTable('profile_fields_definitions')) {
29+
return null;
30+
}
31+
2732
$table = $schema->getTable('profile_fields_definitions');
33+
if (!$table->hasColumn('active')) {
34+
return null;
35+
}
2836

2937
$activeColumn = $table->getColumn('active');
3038
if (!$activeColumn->getNotnull()) {

0 commit comments

Comments
 (0)