diff options
author | Vincent Petry <pvince81@owncloud.com> | 2014-07-07 10:58:23 +0200 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2014-07-07 10:58:23 +0200 |
commit | 5c444c2da8b47546ef120a365b872b4fc078a8cf (patch) | |
tree | 37a065025bb44c7d88749a2fc1704a02452ea75d /lib | |
parent | 6e9905d7cfdde1f94f1bb6f61d7db01c5b419265 (diff) | |
parent | 1565089c02eb8f66afdb58e1d503ddf5dd915d3c (diff) | |
download | nextcloud-server-5c444c2da8b47546ef120a365b872b4fc078a8cf.tar.gz nextcloud-server-5c444c2da8b47546ef120a365b872b4fc078a8cf.zip |
Merge pull request #9468 from owncloud/fix_logout_error_messages
better validation: cadd extra check if appinfo/info.xml exists
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/app.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/private/app.php b/lib/private/app.php index 0ca2ca36bd2..b7d58c72340 100644 --- a/lib/private/app.php +++ b/lib/private/app.php @@ -574,7 +574,7 @@ class OC_App { * Read all app metadata from the info.xml file * @param string $appid id of the app or the path of the info.xml file * @param boolean $path (optional) - * @return array + * @return array|null * @note all data is read from info.xml, not just pre-defined fields */ public static function getAppInfo($appid, $path = false) { @@ -587,6 +587,9 @@ class OC_App { $file = self::getAppPath($appid) . '/appinfo/info.xml'; } $data = array(); + if (!file_exists($file)) { + return null; + } $content = @file_get_contents($file); if (!$content) { return null; |