From 397badec453c021473baaf5f6c84211536c7f71e Mon Sep 17 00:00:00 2001 From: Tim-Hinnerk Heuer Date: Fri, 13 Aug 2021 20:21:57 +1200 Subject: add token_auth to overlay requests where necessary (#17851) * add token_auth to overlay requests where necessary #17640 * ensure all links on overlay page work as expected both, with token_auth and when logged in #17640 * DRY force_api_session=1 and token_auth parameters in broadcast.js and correct in other code for convenience #17640 * polish logic for overlay with token_auth and change minimal logic in client side while validating token_auth in View::shouldPropagateTokenAuthInAjaxRequests() #17640 * use 'string' as string parameter #17640 * simplify token_auth check #17640 * revert git submodule to 4.x-dev version #17640 * return $tokenAuth string (truthy) only, simplify condition, ensure & is prepended to token_auth url param #17640 * revert submodule change * Update core/View.php Co-authored-by: Stefan Giehl Co-authored-by: sgiehl --- plugins/Overlay/javascripts/Piwik_Overlay.js | 1 + 1 file changed, 1 insertion(+) (limited to 'plugins/Overlay/javascripts/Piwik_Overlay.js') diff --git a/plugins/Overlay/javascripts/Piwik_Overlay.js b/plugins/Overlay/javascripts/Piwik_Overlay.js index 49e5c95401..f33382fceb 100644 --- a/plugins/Overlay/javascripts/Piwik_Overlay.js +++ b/plugins/Overlay/javascripts/Piwik_Overlay.js @@ -50,6 +50,7 @@ var Piwik_Overlay = (function () { globalAjaxQueue.abort(); var ajaxRequest = new ajaxHelper(); ajaxRequest.addParams(params, 'get'); + ajaxRequest.withTokenInUrl(); // needed because it is calling a controller and not the API ajaxRequest.setCallback( function (response) { hideLoading(); -- cgit v1.2.3