Merge pull request #9210 from owncloud/better_validation_in_getAppPath
better validation for OC_App::getAppPath()
This commit is contained in:
commit
b7d79a90b0
|
@ -509,6 +509,10 @@ class OC_App {
|
|||
* @return string|false
|
||||
*/
|
||||
public static function getAppPath($appid) {
|
||||
if ($appid === null || trim($appid) === '') {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (($dir = self::findAppInDirectories($appid)) != false) {
|
||||
return $dir['path'] . '/' . $appid;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue