From e08a7c3ea8530ad59ea69e5893509ef7c7065cf3 Mon Sep 17 00:00:00 2001 From: Bjarke Berg Date: Mon, 11 Feb 2019 11:54:51 +0100 Subject: [PATCH] Need to clone the object before removing $-prefixed variables. Otherwise we are modifying the same data as the views are using --- .../donotpostdollarvariablesrequest.interceptor.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Umbraco.Web.UI.Client/src/common/interceptors/donotpostdollarvariablesrequest.interceptor.js b/src/Umbraco.Web.UI.Client/src/common/interceptors/donotpostdollarvariablesrequest.interceptor.js index eabb611320..03373089d7 100644 --- a/src/Umbraco.Web.UI.Client/src/common/interceptors/donotpostdollarvariablesrequest.interceptor.js +++ b/src/Umbraco.Web.UI.Client/src/common/interceptors/donotpostdollarvariablesrequest.interceptor.js @@ -26,7 +26,9 @@ //dealing with requests: 'request': function(config) { if(config.method === "POST"){ - transform(config.data); + var clone = angular.copy(config); + transform(clone.data); + return clone; } return config;