Skip to content

Commit

Permalink
Cosmos: Instance can be null for member translation (#23204)
Browse files Browse the repository at this point in the history
Static methods
  • Loading branch information
smitpatel committed Nov 5, 2020
1 parent 7607893 commit 0032742
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,11 @@ public CosmosMemberTranslatorProvider(
/// doing so can result in application failures when updating to a new Entity Framework Core release.
/// </summary>
public virtual SqlExpression? Translate(
SqlExpression instance,
SqlExpression? instance,
MemberInfo member,
Type returnType,
IDiagnosticsLogger<DbLoggerCategory.Query> logger)
{
Check.NotNull(instance, nameof(instance));
Check.NotNull(member, nameof(member));
Check.NotNull(returnType, nameof(returnType));
Check.NotNull(logger, nameof(logger));
Expand Down
2 changes: 1 addition & 1 deletion src/EFCore.Cosmos/Query/Internal/IMemberTranslator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public interface IMemberTranslator
/// doing so can result in application failures when updating to a new Entity Framework Core release.
/// </summary>
SqlExpression? Translate(
[NotNull] SqlExpression instance,
[CanBeNull] SqlExpression? instance,
[NotNull] MemberInfo member,
[NotNull] Type returnType,
[NotNull] IDiagnosticsLogger<DbLoggerCategory.Query> logger);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public interface IMemberTranslatorProvider
/// doing so can result in application failures when updating to a new Entity Framework Core release.
/// </summary>
SqlExpression? Translate(
[NotNull] SqlExpression instance,
[CanBeNull] SqlExpression? instance,
[NotNull] MemberInfo member,
[NotNull] Type returnType,
[NotNull] IDiagnosticsLogger<DbLoggerCategory.Query> logger);
Expand Down

0 comments on commit 0032742

Please sign in to comment.