Skip to content

ResendEmailConfirmation has bad link #24273

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Youssef1313 opened this issue Jul 24, 2020 · 4 comments
Closed

ResendEmailConfirmation has bad link #24273

Youssef1313 opened this issue Jul 24, 2020 · 4 comments
Labels
area-identity Includes: Identity and providers
Milestone

Comments

@Youssef1313
Copy link
Member

  1. Create a new ASP.NET Core 3.1 app with individual authentication.
  2. Scaffold Login and Register pages.
  3. The resend email link in the login page redirects to https://localhost:5001/?page=%2FAccount%2FResendEmailConfirmation, and it just opens the home page.
  4. Scaffold the ResendEmailConfirmation.
  5. The link now is correct and redirects to https://localhost:44337/Identity/Account/ResendEmailConfirmation which generates an error because of extra abstract keyword InvalidOperationException: Can't compile a NewExpression with a constructor declared on an abstract class. (This was already solved before, but the fix seems to be not shipped with .NET Core 3.1).

To summarize, there are 2 problems:

  1. Wrong link before scaffolding ResendEmailConfirmation
  2. Correct link after scaffolding ResendEmailConfirmation but with the extra abstract keyword (which is fixed but not shipped with .NET Core 3.1).

The main problem for me is the first, I don't want to override anything in ResendEmailConfirmation, but I've to scaffold it.

I'm not sure if the two problems are related to each others or not.

@blowdart blowdart added the area-identity Includes: Identity and providers label Jul 24, 2020
@HaoK
Copy link
Member

HaoK commented Jul 28, 2020

This file doesn't exist in 3.1 as we removed it to bring the feature back in 5.0, so I don't think we are likely going to be fixing it for 3.1, but the feature should work in 5.0 https://github.com/dotnet/aspnetcore/tree/release/3.1/src/Identity/UI/src/Areas/Identity/Pages/V4/Account (note there is no ResendEmailConfirmation.cshtml file)

@Youssef1313
Copy link
Member Author

@HaoK, The 3.1 branch in Scaffolding repo contains the ResendEmailConfirmation file, should it be removed, and also remove the link for it in login page?

I opened dotnet/Scaffolding#1375 a days ago to remove the abstract keyword from Scaffolding repo, but as far as I understood from you now, the change in that PR is incorrect, and the file should completely be deleted, is that correct?

@HaoK
Copy link
Member

HaoK commented Jul 28, 2020

Correct, 3.1 should just remove the file and the link, it should be in 5.0 only, thanks for opening these PRs @Youssef1313

@Youssef1313
Copy link
Member Author

@HaoK, Thanks. I've updated dotnet/Scaffolding#1375. That PR should fix this issue.

@pranavkm pranavkm added this to the 3.1.x milestone Sep 25, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Oct 25, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-identity Includes: Identity and providers
Projects
None yet
Development

No branches or pull requests

4 participants