Skip to content

Commit 8573758

Browse files
committed
Improve App and Route return, fixed File
- Fixed File::isBinary method - Improved show Route return in App::exec
1 parent b306d2e commit 8573758

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Experimental/File.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public static function isBinary($path)
6565
}
6666

6767
$finfo = finfo_open(FILEINFO_MIME_ENCODING);
68-
$encode = finfo_buffer($finfo, file_get_contents($path, false, null, -1, 5012));
68+
$encode = finfo_buffer($finfo, file_get_contents($path, false, null, 0, 5012));
6969
finfo_close($finfo);
7070

7171
return strcasecmp($encode, 'binary') === 0;

src/Inphinit/App.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ public static function exec()
224224

225225
self::trigger('ready');
226226

227-
if ($output) {
227+
if ($output || is_numeric($output)) {
228228
echo $output;
229229
}
230230

0 commit comments

Comments
 (0)