Apply attribute to page model rather than handler
This commit is contained in:
parent
ee7d80881d
commit
c6cc1ef6d6
|
|
@ -13,6 +13,7 @@ namespace Microsoft.AspNetCore.Authentication.AzureAD.UI.Internal
|
|||
/// directly from your code.This API may change or be removed in future releases
|
||||
/// </summary>
|
||||
[AllowAnonymous]
|
||||
[ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)]
|
||||
public class ErrorModel : PageModel
|
||||
{
|
||||
/// <summary>
|
||||
|
|
@ -31,10 +32,9 @@ namespace Microsoft.AspNetCore.Authentication.AzureAD.UI.Internal
|
|||
/// This API supports infrastructure and is not intended to be used
|
||||
/// directly from your code.This API may change or be removed in future releases
|
||||
/// </summary>
|
||||
[ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)]
|
||||
public void OnGet()
|
||||
{
|
||||
RequestId = Activity.Current?.Id ?? HttpContext.TraceIdentifier;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ namespace Microsoft.AspNetCore.Authentication.AzureADB2C.UI.Internal
|
|||
/// directly from your code.This API may change or be removed in future releases
|
||||
/// </summary>
|
||||
[AllowAnonymous]
|
||||
[ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)]
|
||||
public class ErrorModel : PageModel
|
||||
{
|
||||
/// <summary>
|
||||
|
|
@ -31,10 +32,9 @@ namespace Microsoft.AspNetCore.Authentication.AzureADB2C.UI.Internal
|
|||
/// This API supports infrastructure and is not intended to be used
|
||||
/// directly from your code.This API may change or be removed in future releases
|
||||
/// </summary>
|
||||
[ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)]
|
||||
public void OnGet()
|
||||
{
|
||||
RequestId = Activity.Current?.Id ?? HttpContext.TraceIdentifier;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue