Open Closed

difference between <AbpSignInManager>().SignOutAsync() and <LoggedOutModel>().OnGetAsync() #6173


User avatar
0
Priyanka created

What is the difference if we call below mention functions: await httpContext.RequestServices.GetRequiredService<AbpSignInManager>().SignOutAsync(); await httpContext.RequestServices.GetRequiredService<LoggedOutModel>().OnGetAsync();

ABP Framework version: v5.3.2

UI Type:React

Database System: EF Core (SQL Server)

Tiered (for MVC) or Auth Server Separated (for Angular): yes

Exception message and full stack trace:NA

Steps to reproduce the issue: Login and Logout


3 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Please use the AbpSignInManager, The LoggedOutModel is a page model. you can't call it.

  • User Avatar
    0
    Priyanka created

    sure, but what is the difference between both, as per my understanding we can call LoggedOutModel after overriding.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    The page model is designed for the HTTP calls. You should use the AbpSignInManager in your service.

Made with ❤️ on ABP v9.1.0-preview. Updated on December 10, 2024, 06:38