Skip to content
This repository was archived by the owner on Mar 24, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
use extension_load to detect if swoole extension is installed
  • Loading branch information
albertcht committed May 5, 2018
commit 3d381c40ad2ff5fd905ec5e9090855ecb48bd598
1 change: 0 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
],
"require": {
"php": "^7.1",
"ext-swoole": ">=1.9.3 || >=2.1.0",
"illuminate/console": "~5.1",
"illuminate/contracts": "~5.1",
"illuminate/http": "~5.1",
Expand Down
4 changes: 3 additions & 1 deletion src/Commands/HttpServerCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,9 @@ protected function isDaemon()
protected function checkEnvironment()
{
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
throw new \RuntimeException("Swoole extension doesn't support Windows OS yet");
throw new \RuntimeException("Swoole extension doesn't support Windows OS yet.");
} elseif (! extension_loaded('swoole')) {
throw new \RuntimeException("Can't detect Swoole extension installed.");
}
}
}