Skip to content

Commit 9634fb0

Browse files
authored
Fix default dialect settings (#374)
default dialect setting
1 parent c5abd3d commit 9634fb0

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

src/NRedisStack/Search/SearchCommands.cs

+1
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,7 @@ public InfoResult Info(RedisValue index) =>
134134
[Obsolete("Consider using ProfileOnSearch with Redis CE 8.0 and later")]
135135
public Tuple<SearchResult, Dictionary<string, RedisResult>> ProfileSearch(string indexName, Query q, bool limited = false)
136136
{
137+
setDefaultDialectIfUnset(q);
137138
return _db.Execute(SearchCommandBuilder.ProfileSearch(indexName, q, limited))
138139
.ToProfileSearchResult(q);
139140
}

src/NRedisStack/Search/SearchCommandsAsync.cs

+2
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,7 @@ public async Task<InfoResult> InfoAsync(RedisValue index) =>
165165
[Obsolete("Consider using ProfileOnSearchAsync with Redis CE 8.0 and later")]
166166
public async Task<Tuple<SearchResult, Dictionary<string, RedisResult>>> ProfileSearchAsync(string indexName, Query q, bool limited = false)
167167
{
168+
setDefaultDialectIfUnset(q);
168169
return (await _db.ExecuteAsync(SearchCommandBuilder.ProfileSearch(indexName, q, limited)))
169170
.ToProfileSearchResult(q);
170171
}
@@ -179,6 +180,7 @@ public async Task<Tuple<SearchResult, ProfilingInformation>> ProfileOnSearchAsyn
179180
[Obsolete("Consider using ProfileOnSearchAsync with Redis CE 8.0 and later")]
180181
public async Task<Tuple<AggregationResult, Dictionary<string, RedisResult>>> ProfileAggregateAsync(string indexName, AggregationRequest query, bool limited = false)
181182
{
183+
setDefaultDialectIfUnset(query);
182184
return (await _db.ExecuteAsync(SearchCommandBuilder.ProfileAggregate(indexName, query, limited)))
183185
.ToProfileAggregateResult(query);
184186
}

0 commit comments

Comments
 (0)