Skip to content

Commit 77e6c4e

Browse files
committed
Added FindResults<T>.Empty
1 parent 329e9f7 commit 77e6c4e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/Foundatio.Repositories/Models/FindResults.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ namespace Foundatio.Repositories.Models;
1212
[DebuggerDisplay("Total: {Total} Documents: {Documents.Count} Hits: {Hits.Count} Aggs: {Aggregations.Count} Page: {Page} HasMore: {HasMore}")]
1313
public class FindResults<T> : CountResult, IFindResults<T> where T : class
1414
{
15+
public static new readonly FindResults<T> Empty = new();
16+
1517
public FindResults(IEnumerable<FindHit<T>> hits = null, long total = 0, IReadOnlyDictionary<string, IAggregate> aggregations = null, Func<FindResults<T>, Task<FindResults<T>>> getNextPage = null, IDictionary<string, object> data = null)
1618
: base(total, aggregations, data)
1719
{

0 commit comments

Comments
 (0)