mirror of
https://github.com/mempool/mempool.git
synced 2025-02-23 22:46:54 +01:00
Handle empty pools table error
This commit is contained in:
parent
e451b40084
commit
ba12b10f9d
1 changed files with 6 additions and 0 deletions
|
@ -135,6 +135,12 @@ class Blocks {
|
|||
} else {
|
||||
pool = await poolsRepository.$getUnknownPool();
|
||||
}
|
||||
|
||||
if (!pool) { // Something is wrong with the pools table, ignore pool indexing
|
||||
logger.err('Unable to find pool, nor getting the unknown pool. Is the "pools" table empty?');
|
||||
return blockExtended;
|
||||
}
|
||||
|
||||
blockExtended.extras.pool = {
|
||||
id: pool.id,
|
||||
name: pool.name,
|
||||
|
|
Loading…
Add table
Reference in a new issue