Browse Source

Small code refactor in DefaultUserConfirmation.cs (#29310)

Artyom Kolosov 5 years ago
parent
commit
eba0ce1cbb
1 changed files with 1 additions and 5 deletions
  1. 1 5
      src/Identity/Extensions.Core/src/DefaultUserConfirmation.cs

+ 1 - 5
src/Identity/Extensions.Core/src/DefaultUserConfirmation.cs

@@ -19,11 +19,7 @@ namespace Microsoft.AspNetCore.Identity
         /// <returns>The <see cref="Task"/> that represents the asynchronous operation, containing the <see cref="IdentityResult"/> of the confirmation operation.</returns>
         public async virtual Task<bool> IsConfirmedAsync(UserManager<TUser> manager, TUser user)
         {
-            if (!await manager.IsEmailConfirmedAsync(user))
-            {
-                return false;
-            }
-            return true;
+            return await manager.IsEmailConfirmedAsync(user);
         }
     }
 }