summaryrefslogtreecommitdiffstats
path: root/modules/indexer/indexer.go
diff options
context:
space:
mode:
authorkolaente <konrad@kola-entertainments.de>2019-06-12 21:41:28 +0200
committertechknowlogick <techknowlogick@gitea.io>2019-06-12 15:41:28 -0400
commitf9ec2f89f2265bc1371a6c62359de9816534fa6b (patch)
treef48b138a457e5ac6cf843bbb38400926704370f7 /modules/indexer/indexer.go
parent5832f8d90df2d72cb38698c3e9050f2b29717dc7 (diff)
downloadgitea-f9ec2f89f2265bc1371a6c62359de9816534fa6b.tar.gz
gitea-f9ec2f89f2265bc1371a6c62359de9816534fa6b.zip
Add golangci (#6418)
Diffstat (limited to 'modules/indexer/indexer.go')
-rw-r--r--modules/indexer/indexer.go17
1 files changed, 0 insertions, 17 deletions
diff --git a/modules/indexer/indexer.go b/modules/indexer/indexer.go
index 9e12a7f501..29261c693b 100644
--- a/modules/indexer/indexer.go
+++ b/modules/indexer/indexer.go
@@ -5,7 +5,6 @@
package indexer
import (
- "fmt"
"os"
"strconv"
@@ -24,15 +23,6 @@ func indexerID(id int64) string {
return strconv.FormatInt(id, 36)
}
-// idOfIndexerID the integer id associated with an indexer id
-func idOfIndexerID(indexerID string) (int64, error) {
- id, err := strconv.ParseInt(indexerID, 36, 64)
- if err != nil {
- return 0, fmt.Errorf("Unexpected indexer ID %s: %v", indexerID, err)
- }
- return id, nil
-}
-
// numericEqualityQuery a numeric equality query for the given value and field
func numericEqualityQuery(value int64, field string) *query.NumericRangeQuery {
f := float64(value)
@@ -42,13 +32,6 @@ func numericEqualityQuery(value int64, field string) *query.NumericRangeQuery {
return q
}
-func newMatchPhraseQuery(matchPhrase, field, analyzer string) *query.MatchPhraseQuery {
- q := bleve.NewMatchPhraseQuery(matchPhrase)
- q.FieldVal = field
- q.Analyzer = analyzer
- return q
-}
-
const unicodeNormalizeName = "unicodeNormalize"
func addUnicodeNormalizeTokenFilter(m *mapping.IndexMappingImpl) error {