File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -373,7 +373,7 @@ async function initializeFallback(uri: string): Promise<void> {
373373 await initialize ( )
374374}
375375
376- connection . onInitialize ( async ( initParams : lsp . InitializeParams ) : Promise < lsp . InitializeResult > => {
376+ const onInitialize = async ( initParams : lsp . InitializeParams ) : Promise < lsp . InitializeResult > => {
377377 console . info ( "Started new session" )
378378 console . info ( "Running in" , initParams . clientInfo ?. name )
379379 console . info ( "workspaceFolders:" , initParams . workspaceFolders )
@@ -942,6 +942,14 @@ connection.onInitialize(async (initParams: lsp.InitializeParams): Promise<lsp.In
942942 } ,
943943 } ,
944944 }
945+ }
946+ connection . onInitialize ( async ( initParams : lsp . InitializeParams ) : Promise < lsp . InitializeResult > => {
947+ try {
948+ return await onInitialize ( initParams )
949+ } catch ( error ) {
950+ console . error ( error )
951+ }
952+ return { }
945953} )
946954
947955Logger . initialize ( connection , `${ __dirname } /ton-language-server.log` )
You can’t perform that action at this time.
0 commit comments