aergoio/aergo

View on GitHub
pkg/trie/trie_tools.go

Summary

Maintainability
A
1 hr
Test Coverage
B
81%

Method Trie.get has 6 return statements (exceeds 4 allowed).
Open

func (s *Trie) get(root, key []byte, batch [][]byte, iBatch, height int) ([]byte, error) {
    if len(root) == 0 {
        // the trie does not contain the key
        return nil, nil
    }
Severity: Major
Found in pkg/trie/trie_tools.go - About 40 mins to fix

    Method Trie.loadCache has 5 return statements (exceeds 4 allowed).
    Open

    func (s *Trie) loadCache(root []byte, batch [][]byte, iBatch, height int, ch chan<- (error)) {
        if height < s.CacheHeightLimit || len(root) == 0 {
            ch <- nil
            return
        }
    Severity: Major
    Found in pkg/trie/trie_tools.go - About 35 mins to fix

      There are no issues that match your filters.

      Category
      Status