Skip to content

Commit 1da3328

Browse files
committed
fix: allow rootUri to be null
Fixes felixfbecker#684
1 parent 450116e commit 1da3328

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/LanguageServer.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ public function __construct(ProtocolReader $reader, ProtocolWriter $writer)
167167
*/
168168
public function initialize(ClientCapabilities $capabilities, string $rootPath = null, int $processId = null, string $rootUri = null): Promise
169169
{
170-
if ($rootPath === null) {
170+
if ($rootPath === null && $rootUri !== null) {
171171
$rootPath = uriToPath($rootUri);
172172
}
173173
return coroutine(function () use ($capabilities, $rootPath, $processId) {

0 commit comments

Comments
 (0)