Skip to content
Extraits de code Groupes Projets
Valider ab0765a3 rédigé par Matthieu Aubry's avatar Matthieu Aubry
Parcourir les fichiers

Merge pull request #8807 from Joey3000/fixHardcodedLogin

Fix hardcoded Login module references
parents 0d0f7f21 a2962c3d
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -879,7 +879,7 @@ abstract class Controller ...@@ -879,7 +879,7 @@ abstract class Controller
$currentLogin = Piwik::getCurrentUserLogin(); $currentLogin = Piwik::getCurrentUserLogin();
$emails = implode(',', Piwik::getAllSuperUserAccessEmailAddresses()); $emails = implode(',', Piwik::getAllSuperUserAccessEmailAddresses());
$errorMessage = sprintf(Piwik::translate('CoreHome_NoPrivilegesAskPiwikAdmin'), $currentLogin, "<br/><a href='mailto:" . $emails . "?subject=Access to Piwik for user $currentLogin'>", "</a>"); $errorMessage = sprintf(Piwik::translate('CoreHome_NoPrivilegesAskPiwikAdmin'), $currentLogin, "<br/><a href='mailto:" . $emails . "?subject=Access to Piwik for user $currentLogin'>", "</a>");
$errorMessage .= "<br /><br />&nbsp;&nbsp;&nbsp;<b><a href='index.php?module=" . StaticContainer::get('Piwik\Auth')->getName() . "&amp;action=logout'>&rsaquo; " . Piwik::translate('General_Logout') . "</a></b><br />"; $errorMessage .= "<br /><br />&nbsp;&nbsp;&nbsp;<b><a href='index.php?module=" . Piwik::getLoginPluginName() . "&amp;action=logout'>&rsaquo; " . Piwik::translate('General_Logout') . "</a></b><br />";
$ex = new NoPrivilegesException($errorMessage); $ex = new NoPrivilegesException($errorMessage);
$ex->setIsHtmlMessage(); $ex->setIsHtmlMessage();
......
...@@ -176,7 +176,7 @@ class Controller extends \Piwik\Plugin\Controller ...@@ -176,7 +176,7 @@ class Controller extends \Piwik\Plugin\Controller
</div>', </div>',
Piwik::translate('General_Error'), Piwik::translate('General_Error'),
htmlentities($errorMessage, Common::HTML_ENCODING_QUOTE_STYLE, 'UTF-8', $doubleEncode = false), htmlentities($errorMessage, Common::HTML_ENCODING_QUOTE_STYLE, 'UTF-8', $doubleEncode = false),
'index.php?module=Login', 'index.php?module=' . Piwik::getLoginPluginName(),
Piwik::translate('Login_LogIn') Piwik::translate('Login_LogIn')
); );
} }
......
...@@ -57,11 +57,11 @@ class Login extends \Piwik\Plugin ...@@ -57,11 +57,11 @@ class Login extends \Piwik\Plugin
$frontController = FrontController::getInstance(); $frontController = FrontController::getInstance();
if (Common::isXmlHttpRequest()) { if (Common::isXmlHttpRequest()) {
echo $frontController->dispatch('Login', 'ajaxNoAccess', array($exception->getMessage())); echo $frontController->dispatch(Piwik::getLoginPluginName(), 'ajaxNoAccess', array($exception->getMessage()));
return; return;
} }
echo $frontController->dispatch('Login', 'login', array($exception->getMessage())); echo $frontController->dispatch(Piwik::getLoginPluginName(), 'login', array($exception->getMessage()));
} }
/** /**
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter