mirror of
https://github.com/mempool/mempool.git
synced 2025-09-20 16:50:46 +02:00
Add db migration to remove bad price data
This commit is contained in:
@@ -7,7 +7,7 @@ import cpfpRepository from '../repositories/CpfpRepository';
|
||||
import { RowDataPacket } from 'mysql2';
|
||||
|
||||
class DatabaseMigration {
|
||||
private static currentVersion = 100;
|
||||
private static currentVersion = 101;
|
||||
private queryTimeout = 3600_000;
|
||||
private statisticsAddedIndexed = false;
|
||||
private uniqueLogs: string[] = [];
|
||||
@@ -1299,6 +1299,10 @@ class DatabaseMigration {
|
||||
queries.push(`DELETE FROM state WHERE name = 'last_weekly_hashrates_indexing'`);
|
||||
}
|
||||
|
||||
if (version < 101) {
|
||||
queries.push(`DELETE FROM prices WHERE USD = -1`);
|
||||
}
|
||||
|
||||
return queries;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user