From de73ba725613118b50101e00b0e8f2f5e5a4e45a Mon Sep 17 00:00:00 2001 From: Kenn Jacobsen Date: Tue, 16 Aug 2022 09:29:52 +0200 Subject: [PATCH] Fix JS error when clicking a reset password link twice (#12845) --- .../Extensions/HtmlHelperBackOfficeExtensions.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Umbraco.Web.BackOffice/Extensions/HtmlHelperBackOfficeExtensions.cs b/src/Umbraco.Web.BackOffice/Extensions/HtmlHelperBackOfficeExtensions.cs index dbe5b0f7b0..1773969563 100644 --- a/src/Umbraco.Web.BackOffice/Extensions/HtmlHelperBackOfficeExtensions.cs +++ b/src/Umbraco.Web.BackOffice/Extensions/HtmlHelperBackOfficeExtensions.cs @@ -104,7 +104,7 @@ public static class HtmlHelperBackOfficeExtensions /// /// /// - public static IHtmlContent AngularValueResetPasswordCodeInfoScript(this IHtmlHelper html, object val) + public static IHtmlContent AngularValueResetPasswordCodeInfoScript(this IHtmlHelper html, object? val) { var sb = new StringBuilder(); sb.AppendLine(); @@ -116,6 +116,8 @@ public static class HtmlHelperBackOfficeExtensions { sb.AppendFormat(@"errors.push(""{0}"");", error).AppendLine(); } + + val = null; } sb.AppendLine(@"app.value(""resetPasswordCodeInfo"", {");