Skip to content

Commit 59bfada

Browse files
committed
Use constants
1 parent e6bfcf4 commit 59bfada

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

packages/dev-server/src/Server.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@
2121
use React\EventLoop\Loop;
2222
use Symfony\Contracts\EventDispatcher\EventDispatcherInterface;
2323

24+
use const SIGINT;
25+
2426
class Server
2527
{
2628
private INotifyWatcher $watcher;
@@ -38,7 +40,8 @@ public function __construct(
3840
$logger->info('Shutting down server...');
3941
$loop->stop();
4042
$logger->info('Server stopped');
41-
exit(0);
43+
44+
exit(0); // phpcs:ignore
4245
});
4346
}
4447

packages/dev-server/src/Watcher/INotifyWatcher.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,16 @@
1818
use RuntimeException;
1919

2020
use function inotify_add_watch;
21+
use function inotify_init;
2122
use function inotify_read;
2223
use function stream_set_blocking;
2324
use function var_dump;
2425

2526
use const DIRECTORY_SEPARATOR;
27+
use const IN_CLOSE_WRITE;
28+
use const IN_CREATE;
29+
use const IN_DELETE;
30+
use const IN_MODIFY;
2631

2732
class INotifyWatcher
2833
{

0 commit comments

Comments
 (0)