Skip to content

Commit

Permalink
Merge pull request #166 from oat-sa/hotfix/sql-error
Browse files Browse the repository at this point in the history
Fix SQL error at update on fingerprint_xxx columns
  • Loading branch information
jbout authored Dec 13, 2017
2 parents 28d15af + 9bcd313 commit 59ad551
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion manifest.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
'label' => 'Browser and OS diagnostic tool',
'description' => 'Check compatibility of the os and browser of a client',
'license' => 'GPL-2.0',
'version' => '2.9.0',
'version' => '2.9.0.1',
'author' => 'Open Assessment Technologies SA',
'requires' => array(
'tao' => '>=14.2.0',
Expand Down
4 changes: 2 additions & 2 deletions scripts/install/createDiagnosticTable.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ public function __invoke($params)
$tableResults->addColumn(Sql::DIAGNOSTIC_USER_ID, 'string', ['length' => 255, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_IP, 'string', ['length' => 32]);
$tableResults->addColumn(Sql::DIAGNOSTIC_WORKSTATION, 'string', ['length' => 64, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_UUID, 'string', ['length' => 32]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_VALUE, 'string', ['length' => 32]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_UUID, 'string', ['length' => 32, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_VALUE, 'string', ['length' => 32, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_DETAILS, 'text', ['notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_ERRORS, 'integer', ['length' => 1, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_CHANGED, 'integer', ['length' => 1, 'notnull' => false]);
Expand Down
6 changes: 4 additions & 2 deletions scripts/update/Updater.php
Original file line number Diff line number Diff line change
Expand Up @@ -560,8 +560,8 @@ public function update($initialVersion)
/** @var \Doctrine\DBAL\Schema\Table $tableResults */
$tableResults = $schema->getTable(Sql::DIAGNOSTIC_TABLE);

$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_UUID, 'string', ['length' => 32]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_VALUE, 'string', ['length' => 32]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_UUID, 'string', ['length' => 32, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_VALUE, 'string', ['length' => 32, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_DETAILS, 'text', ['notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_ERRORS, 'integer', ['length' => 1, 'notnull' => false]);
$tableResults->addColumn(Sql::DIAGNOSTIC_FINGERPRINT_CHANGED, 'integer', ['length' => 1, 'notnull' => false]);
Expand All @@ -574,5 +574,7 @@ public function update($initialVersion)

$this->setVersion('2.9.0');
}

$this->skip('2.9.0', '2.9.0.1');
}
}

0 comments on commit 59ad551

Please sign in to comment.