From 29ce56ed07cba66b6cfe7070c0a46f5a93ff873c Mon Sep 17 00:00:00 2001 From: Lukas Reschke Date: Fri, 12 Feb 2016 10:36:43 +0100 Subject: [PATCH] Check if admin user We should not add the JS for not admin users. --- lib/private/templatelayout.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/private/templatelayout.php b/lib/private/templatelayout.php index 7166b23d4c..5afbd4495c 100644 --- a/lib/private/templatelayout.php +++ b/lib/private/templatelayout.php @@ -72,7 +72,7 @@ class TemplateLayout extends \OC_Template { // Code integrity notification $integrityChecker = \OC::$server->getIntegrityCodeChecker(); - if(!$integrityChecker->hasPassedCheck()) { + if(\OC_User::isAdminUser(\OC_User::getUser()) && !$integrityChecker->hasPassedCheck()) { \OCP\Util::addScript('core', 'integritycheck-failed-notification'); }