all: Bunch of more linter fixes (#5500)

This commit is contained in:
Jakob Borg
2019-02-02 11:02:28 +01:00
committed by GitHub
parent 2111386ee4
commit df5c1eaf01
30 changed files with 118 additions and 117 deletions

View File

@@ -82,7 +82,7 @@ func (i *smallIndex) ID(val []byte) uint32 {
key := make([]byte, len(i.prefix)+8) // prefix plus uint32 id
copy(key, i.prefix)
binary.BigEndian.PutUint32(key[len(i.prefix):], id)
i.db.Put(key, val, nil)
_ = i.db.Put(key, val, nil)
i.mut.Unlock()
return id
@@ -115,7 +115,7 @@ func (i *smallIndex) Delete(val []byte) {
// Put an empty value into the database. This indicates that the
// entry does not exist any more and prevents the ID from being
// reused in the future.
i.db.Put(key, []byte{}, nil)
_ = i.db.Put(key, []byte{}, nil)
// Delete reverse mapping.
delete(i.id2val, id)