mirror of
https://github.com/mempool/mempool.git
synced 2025-03-15 12:20:28 +01:00
Merge pull request #5798 from mempool/mononaut/fix-audits-timestamp
disabled ON UPDATE for blocks_audits time field
This commit is contained in:
commit
8b435b7aa3
1 changed files with 6 additions and 1 deletions
|
@ -7,7 +7,7 @@ import cpfpRepository from '../repositories/CpfpRepository';
|
||||||
import { RowDataPacket } from 'mysql2';
|
import { RowDataPacket } from 'mysql2';
|
||||||
|
|
||||||
class DatabaseMigration {
|
class DatabaseMigration {
|
||||||
private static currentVersion = 95;
|
private static currentVersion = 96;
|
||||||
private queryTimeout = 3600_000;
|
private queryTimeout = 3600_000;
|
||||||
private statisticsAddedIndexed = false;
|
private statisticsAddedIndexed = false;
|
||||||
private uniqueLogs: string[] = [];
|
private uniqueLogs: string[] = [];
|
||||||
|
@ -1130,6 +1130,11 @@ class DatabaseMigration {
|
||||||
await this.$executeQuery('ALTER TABLE blocks ADD INDEX `definition_hash` (`definition_hash`)');
|
await this.$executeQuery('ALTER TABLE blocks ADD INDEX `definition_hash` (`definition_hash`)');
|
||||||
await this.updateToSchemaVersion(95);
|
await this.updateToSchemaVersion(95);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (databaseSchemaVersion < 96) {
|
||||||
|
await this.$executeQuery(`ALTER TABLE blocks_audits MODIFY time timestamp NOT NULL DEFAULT 0`);
|
||||||
|
await this.updateToSchemaVersion(96);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Reference in a new issue