I try to add Identity to my web API, but get this error
InvalidOperationException: Unable to resolve service for type >'Microsoft.AspNetCore.Authentication.ISystemClock' while attempting to activate >'Microsoft.AspNetCore.Identity.SecurityStampValidator`1[WebAPI.Models.User>]'.
after adding Identity in Startup.cs, where I have this
services.AddIdentityCore<User>(options => { });
new IdentityBuilder(typeof(User), typeof(IdentityRole), services)
.AddRoleManager<RoleManager<IdentityRole>>()
.AddSignInManager<SignInManager<User>>()
.AddEntityFrameworkStores<DataContext>();
app.UseAuthentication();
The usermodel class is empty. Everything is loaded into the database. What is missing? I appreciate your time and help.