core: fix mempool error check in PoolTx

ErrAlreadyExists should be returned for ErrDup, not ErrConflict.
This commit is contained in:
Roman Khimov 2020-08-06 19:41:26 +03:00
parent 0e2784cd2c
commit 4c38fae54c

View file

@ -1381,7 +1381,7 @@ func (bc *Blockchain) PoolTx(t *transaction.Transaction) error {
switch err {
case mempool.ErrOOM:
return ErrOOM
case mempool.ErrConflict:
case mempool.ErrDup:
return fmt.Errorf("mempool: %w", ErrAlreadyExists)
default:
return err