aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/Controllers/updateController.php5
-rw-r--r--lib/Minz/ExtensionManager.php3
2 files changed, 7 insertions, 1 deletions
diff --git a/app/Controllers/updateController.php b/app/Controllers/updateController.php
index 61b62773b..4797a3486 100644
--- a/app/Controllers/updateController.php
+++ b/app/Controllers/updateController.php
@@ -28,7 +28,10 @@ class FreshRSS_update_Controller extends Minz_ActionController {
);
} elseif (file_exists(UPDATE_FILENAME)) {
// There is an update file to apply!
- $version = file_get_contents(join_path(DATA_PATH, 'last_update.txt'));
+ $version = @file_get_contents(join_path(DATA_PATH, 'last_update.txt'));
+ if (empty($version)) {
+ $version = 'unknown';
+ }
$this->view->update_to_apply = true;
$this->view->message = array(
'status' => 'good',
diff --git a/lib/Minz/ExtensionManager.php b/lib/Minz/ExtensionManager.php
index 7edc7afaa..f00453f6c 100644
--- a/lib/Minz/ExtensionManager.php
+++ b/lib/Minz/ExtensionManager.php
@@ -56,6 +56,9 @@ class Minz_ExtensionManager {
foreach ($list_potential_extensions as $ext_dir) {
$ext_pathname = EXTENSIONS_PATH . '/' . $ext_dir;
+ if (!is_dir($ext_pathname)) {
+ continue;
+ }
$metadata_filename = $ext_pathname . '/' . self::$ext_metaname;
// Try to load metadata file.