/** * check the code of an app with some static code checks * @param string $folder the folder of the app to check * @return boolean true for app is o.k. and false for app is not o.k. */ public static function checkCode($folder) { // is the code checker enabled? if (!\OC::$server->getConfig()->getSystemValue('appcodechecker', false)) { return true; } $codeChecker = new \OC\App\CodeChecker(); $errors = $codeChecker->analyseFolder($folder); return empty($errors); }