Skip to content
Snippets Groups Projects
Commit db77dc91 authored by Frank Karlitschek's avatar Frank Karlitschek
Browse files

only try to install apps that are compatible with oC4

parent 2e9115ef
No related branches found
No related tags found
No related merge requests found
......@@ -130,10 +130,19 @@ class OC_Installer{
// check the code for not allowed calls
if(!OC_Installer::checkCode($info['id'],$extractDir)){
OC_Log::write('core','App can\'t be installed because of not allowed code in the App',OC_Log::ERROR);
OC_Helper::rmdirr($extractDir);
return false;
}
// check if the app is compatible with this version of ownCloud
$version=OC_Util::getVersion();
if(!isset($info['require']) or ($version[0]>$info['require'])){
OC_Log::write('core','App can\'t be installed because it is not compatible with this version of ownCloud',OC_Log::ERROR);
OC_Helper::rmdirr($extractDir);
return false;
}
//check if an app with the same id is already installed
if(self::isInstalled( $info['id'] )){
OC_Log::write('core','App already installed',OC_Log::WARN);
......
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