소스 검색

优化代码 (#1939)

vic 2 년 전
부모
커밋
6d3ed98744
1개의 변경된 파일1개의 추가작업 그리고 5개의 파일을 삭제
  1. 1 5
      core/bloom/bloom.go

+ 1 - 5
core/bloom/bloom.go

@@ -69,11 +69,7 @@ func (f *Filter) Exists(data []byte) (bool, error) {
 	if err != nil {
 		return false, err
 	}
-	if !isSet {
-		return false, nil
-	}
-
-	return true, nil
+	return isSet, nil
 }
 
 func (f *Filter) getLocations(data []byte) []uint {