Skip to content
Snippets Groups Projects
Unverified Commit 13892417 authored by Joas Schilling's avatar Joas Schilling
Browse files

Do not show the hint when it's the same as the message

parent 7b4459d2
No related branches found
No related tags found
No related merge requests found
......@@ -316,6 +316,11 @@ class OC_Template extends \OC\Template\Base {
* @param string $hint An optional hint message - needs to be properly escaped
*/
public static function printErrorPage( $error_msg, $hint = '' ) {
if ($error_msg === $hint) {
// If the hint is the same as the message there is no need to display it twice.
$hint = '';
}
try {
$content = new \OC_Template( '', 'error', 'error', false );
$errors = array(array('error' => $error_msg, 'hint' => $hint));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment