better validation for OC_App::getAppPath()

This commit is contained in:
Georg Ehrke 2014-06-25 16:24:55 +02:00
parent 16396e2e33
commit 09356bc5b3

View file

@ -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;
}