mirror of
https://github.com/go-gitea/gitea
synced 2025-07-21 01:38:37 +00:00
Improve issue search (#2387)
* Improve issue indexer * Fix new issue sqlite bug * Different test indexer paths for each db * Add integration indexer paths to make clean
This commit is contained in:
14
vendor/github.com/blevesearch/bleve/search/highlight/term_locations.go
generated
vendored
14
vendor/github.com/blevesearch/bleve/search/highlight/term_locations.go
generated
vendored
@@ -23,7 +23,7 @@ import (
|
||||
|
||||
type TermLocation struct {
|
||||
Term string
|
||||
ArrayPositions []float64
|
||||
ArrayPositions search.ArrayPositions
|
||||
Pos int
|
||||
Start int
|
||||
End int
|
||||
@@ -103,15 +103,3 @@ func OrderTermLocations(tlm search.TermLocationMap) TermLocations {
|
||||
sort.Sort(rv)
|
||||
return rv
|
||||
}
|
||||
|
||||
func SameArrayPositions(fieldArrayPositions []uint64, termLocationArrayPositions []float64) bool {
|
||||
if len(fieldArrayPositions) != len(termLocationArrayPositions) {
|
||||
return false
|
||||
}
|
||||
for i := 0; i < len(fieldArrayPositions); i++ {
|
||||
if fieldArrayPositions[i] != uint64(termLocationArrayPositions[i]) {
|
||||
return false
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
Reference in New Issue
Block a user