@@ -769,22 +769,18 @@ async function updateWebAndAbstractDocsCaches(wsFolders: readonly vscode.Workspa
769769 return Promise . allSettled (
770770 connections . map ( async ( connection ) => {
771771 if ( ! cspApps . has ( connection . key ) ) {
772- cspApps . set (
773- connection . key ,
774- await connection . api
775- . getCSPApps ( )
776- . then ( ( data ) => data . result . content ?? [ ] )
777- . catch ( ( ) => [ ] )
778- ) ;
772+ const apps = await connection . api
773+ . getCSPApps ( )
774+ . then ( ( data ) => data ?. result ?. content )
775+ . catch ( ( ) => undefined ) ;
776+ if ( apps ) cspApps . set ( connection . key , apps ) ;
779777 }
780778 if ( ! otherDocExts . has ( connection . key ) ) {
781- otherDocExts . set (
782- connection . key ,
783- await connection . api
784- . actionQuery ( "SELECT Extention FROM %Library.RoutineMgr_DocumentTypes()" , [ ] )
785- . then ( ( data ) => data . result ?. content ?. map ( ( e ) => e . Extention ) ?? [ ] )
786- . catch ( ( ) => [ ] )
787- ) ;
779+ const exts = await connection . api
780+ . actionQuery ( "SELECT Extention FROM %Library.RoutineMgr_DocumentTypes()" , [ ] )
781+ . then ( ( data ) => data . result ?. content ?. map ( ( e ) => e . Extention ) )
782+ . catch ( ( ) => undefined ) ;
783+ if ( exts ) otherDocExts . set ( connection . key , exts ) ;
788784 }
789785 } )
790786 ) ;
@@ -1598,6 +1594,7 @@ export async function activate(context: vscode.ExtensionContext): Promise<any> {
15981594 // This unavoidably switches to the File Explorer view, so only do it if isfs folders were found
15991595 vscode . commands . executeCommand ( "workbench.files.action.refreshFilesExplorer" ) ;
16001596 }
1597+ updateWebAndAbstractDocsCaches ( vscode . workspace . workspaceFolders ) ;
16011598 }
16021599 if ( affectsConfiguration ( "objectscript.commentToken" ) ) {
16031600 // Update the language configuration for "objectscript" and "objectscript-macros"
0 commit comments