File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed
src/Umbraco.Commerce.Checkout/Web/Controllers Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change
1
+ using Microsoft . AspNetCore . Mvc . Filters ;
2
+
3
+ namespace Umbraco . Commerce . Checkout . Web . Controllers . Filters
4
+ {
5
+ /// <summary>
6
+ /// Add "cache-control: no-store" header to the response.
7
+ /// </summary>
8
+ internal sealed class NoStoreCacheControlAttribute : ActionFilterAttribute
9
+ {
10
+ public override void OnActionExecuted ( ActionExecutedContext context )
11
+ {
12
+ context . HttpContext . Response . Headers . CacheControl = "no-store" ;
13
+ }
14
+ }
15
+ }
Original file line number Diff line number Diff line change 8
8
using Umbraco . Commerce . Core . Api ;
9
9
using Umbraco . Commerce . Core . Models ;
10
10
using Umbraco . Extensions ;
11
+ using Umbraco . Commerce . Checkout . Web . Controllers . Filters ;
11
12
12
13
namespace Umbraco . Commerce . Checkout . Web . Controllers
13
14
{
15
+ [ NoStoreCacheControl ]
14
16
public abstract class UmbracoCommerceCheckoutBaseController : RenderController
15
17
{
16
18
protected UmbracoCommerceCheckoutBaseController (
You can’t perform that action at this time.
0 commit comments