mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-09 20:59:23 +00:00
Remove error case which shouldn't be an error
This commit is contained in:
@@ -47,6 +47,9 @@ where
|
|||||||
mut block: BlockImportParams<T::Block, Self::Transaction>,
|
mut block: BlockImportParams<T::Block, Self::Transaction>,
|
||||||
new_cache: HashMap<CacheKeyId, Vec<u8>>,
|
new_cache: HashMap<CacheKeyId, Vec<u8>>,
|
||||||
) -> Result<ImportResult, Self::Error> {
|
) -> Result<ImportResult, Self::Error> {
|
||||||
|
if self.client.status(BlockId::Hash(block.hash)).unwrap() == BlockStatus::InChain {
|
||||||
|
return Ok(ImportResult::AlreadyInChain);
|
||||||
|
}
|
||||||
self.check(&mut block).await?;
|
self.check(&mut block).await?;
|
||||||
self.client.import_block(block, new_cache).await.map_err(Into::into)
|
self.client.import_block(block, new_cache).await.map_err(Into::into)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user