Skip to content

Commit cc7d6d8

Browse files
authored
Merge pull request #40 from mateusan/master
fix: Type: Error; Message: Typed property Bloatless\WebSocket\Server::$timers must not be accessed before initialization
2 parents 3a1cecc + c31e172 commit cc7d6d8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Server.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ public function __construct(
124124
$this->host = $host;
125125
$this->port = $port;
126126
$this->ipcSocketPath = $ipcSocketPath;
127+
$this->timers = new TimerCollection();
127128
}
128129

129130
/**
@@ -137,7 +138,6 @@ public function run(): void
137138
ob_implicit_flush();
138139
$this->createSocket($this->host, $this->port);
139140
$this->openIPCSocket($this->ipcSocketPath);
140-
$this->timers = new TimerCollection();
141141
$this->log('Server created');
142142

143143
while (true) {

0 commit comments

Comments
 (0)