v0.0.320 bugfix sort
All checks were successful
Build Docker and Deploy / Run goext test-suite (push) Successful in 1m14s

This commit is contained in:
Timo Vetter 2023-11-14 14:50:27 +01:00
parent 5ba84bd8ee
commit 8528b5cb66
2 changed files with 3 additions and 3 deletions

View File

@ -1,5 +1,5 @@
package goext package goext
const GoextVersion = "0.0.319" const GoextVersion = "0.0.320"
const GoextVersionTimestamp = "2023-11-13T16:45:00+0100" const GoextVersionTimestamp = "2023-11-14T14:50:27+0100"

View File

@ -42,7 +42,7 @@ func (c *Coll[TData]) Paginate(ctx context.Context, filter pag.Filter, page int,
pipelineCount := mongo.Pipeline{} pipelineCount := mongo.Pipeline{}
pipelineCount = append(pipelineCount, bson.D{{Key: "$count", Value: "count"}}) pipelineCount = append(pipelineCount, bson.D{{Key: "$count", Value: "count"}})
pipelineList := langext.ArrConcat(pipelineFilter, pipelineSort, pipelinePaginate, c.extraModPipeline) pipelineList := langext.ArrConcat(pipelineFilter, pipelineSort, pipelinePaginate, c.extraModPipeline, pipelineSort)
pipelineTotalCount := langext.ArrConcat(pipelineFilter, pipelineCount) pipelineTotalCount := langext.ArrConcat(pipelineFilter, pipelineCount)
cursorList, err := c.coll.Aggregate(ctx, pipelineList) cursorList, err := c.coll.Aggregate(ctx, pipelineList)