Skip to content

Commit

Permalink
Fix throwing exception.
Browse files Browse the repository at this point in the history
  • Loading branch information
yunosh committed Mar 7, 2017
1 parent 300de58 commit 227e910
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion framework/Refactor/lib/Horde/Refactor/Config.php
Expand Up @@ -57,8 +57,11 @@ public function __construct($file = null)
if (!$file) {
return;
}
if (!file_exists($file)) {
throw new \InvalidArgumentException("$file not found");
}
if (!is_readable($file)) {
throw InvalidArgumentException("Reading of $file not allowed");
throw new \InvalidArgumentException("Reading of $file not allowed");
}
include $file;
if (!isset($config)) {
Expand Down

0 comments on commit 227e910

Please sign in to comment.