You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Actual Behavior:
VS popup tip on return canBeNull says that "canBeNull is not null here". MS Docs tells "If no entity is found, then null is returned", doc comments in metadata of DbSet tells the same.
Change DbSet<string> dbSetStrings to DbSet<string?> dbSetStrings and tip says "may be null here" on return canBeNull.
Expected Behavior: DbSet<TEntity>.FindAsync() may return ValueTask with null, so the return type must be ValueTask<TEntity?>.
BTW, the method return type from metadata is ValueTask<TEntity>, but it shows Task<TEntity> in the Docs.
The text was updated successfully, but these errors were encountered:
Version Used:
VS 2019 Version 16.5.1
.NET Core 3.1.3
Also tested on:
VS 2019 16.6.0 Preview 2.0
.NET 5.0.0-preview.1
Steps to Reproduce:
Actual Behavior:
VS popup tip on
return canBeNull
says that "canBeNull
is not null here". MS Docs tells "If no entity is found, then null is returned", doc comments in metadata of DbSet tells the same.Change
DbSet<string> dbSetStrings
toDbSet<string?> dbSetStrings
and tip says "may be null here" onreturn canBeNull
.Expected Behavior:
DbSet<TEntity>.FindAsync()
may returnValueTask
withnull
, so the return type must beValueTask<TEntity?>
.BTW, the method return type from metadata is
ValueTask<TEntity>
, but it showsTask<TEntity>
in the Docs.The text was updated successfully, but these errors were encountered: