lint: various fixes

## Description

various linitng fixes
This commit is contained in:
Marko
2020-05-18 10:20:06 +00:00
committed by GitHub
parent d1d33057dc
commit 9149ee7d8b
14 changed files with 36 additions and 44 deletions
+1 -1
View File
@@ -707,7 +707,7 @@ func (cache *mapTxCache) Push(tx types.Tx) bool {
if cache.list.Len() >= cache.size {
popped := cache.list.Front()
poppedTxHash := popped.Value.([sha256.Size]byte)
poppedTxHash := popped.Value.([sha256.Size]byte) //nolint:staticcheck // SA5011: possible nil pointer dereference
delete(cache.cacheMap, poppedTxHash)
if popped != nil {
cache.list.Remove(popped)