Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Giehl <stefan@matomo.org>2019-03-28 10:43:56 +0300
committerGitHub <noreply@github.com>2019-03-28 10:43:56 +0300
commit6aedd2a147cd966487058910da5c9d9c8fcc8f89 (patch)
tree8a6afc86ce7844c6beaf767ebe0d6543fed78162 /plugins/Dashboard
parent93df2e7c61b800ba0627c4d02825d3697a836833 (diff)
Fix dashboard copy to user with special chars (#14197)
* Fix dashboard copy to users with special chars * improve exception message
Diffstat (limited to 'plugins/Dashboard')
-rw-r--r--plugins/Dashboard/API.php2
-rw-r--r--plugins/Dashboard/javascripts/dashboard.js2
2 files changed, 2 insertions, 2 deletions
diff --git a/plugins/Dashboard/API.php b/plugins/Dashboard/API.php
index d00d27d8ba..5367760f2f 100644
--- a/plugins/Dashboard/API.php
+++ b/plugins/Dashboard/API.php
@@ -126,7 +126,7 @@ class API extends \Piwik\Plugin\API
}
if (!$userFound) {
- throw new \Exception(sprintf('Cannot copy dashboard to user %s, user not found or user does not have access to same site.', $copyToUser));
+ throw new \Exception(sprintf('Cannot copy dashboard to user %s, user not found.', $copyToUser));
}
$login = Piwik::getCurrentUserLogin();
diff --git a/plugins/Dashboard/javascripts/dashboard.js b/plugins/Dashboard/javascripts/dashboard.js
index 86faf58b52..e8a2857e53 100644
--- a/plugins/Dashboard/javascripts/dashboard.js
+++ b/plugins/Dashboard/javascripts/dashboard.js
@@ -136,7 +136,7 @@ function copyDashboardToUser() {
ajaxRequest.addParams({
dashboardName: encodeURIComponent(copyDashboardName),
idDashboard: $('#dashboardWidgetsArea').dashboard('getDashboardId'),
- copyToUser: encodeURIComponent(copyDashboardUser)
+ copyToUser: copyDashboardUser
}, 'post');
ajaxRequest.setCallback(
function (response) {