File tree Expand file tree Collapse file tree 2 files changed +81
-15
lines changed Expand file tree Collapse file tree 2 files changed +81
-15
lines changed Original file line number Diff line number Diff line change @@ -758,7 +758,7 @@ impl Server {
758
758
} ) ;
759
759
}
760
760
761
- fn refresh_schema_cache ( & self ) {
761
+ async fn refresh_schema_cache ( & self ) {
762
762
if self . db_conn . is_none ( ) {
763
763
return ;
764
764
}
@@ -767,17 +767,15 @@ impl Server {
767
767
let conn = self . db_conn . as_ref ( ) . unwrap ( ) . pool . clone ( ) ;
768
768
let client = self . client . clone ( ) ;
769
769
770
- async_std:: task:: spawn ( async move {
771
- client
772
- . send_notification :: < ShowMessage > ( ShowMessageParams {
773
- typ : lsp_types:: MessageType :: INFO ,
774
- message : "Refreshing schema cache..." . to_string ( ) ,
775
- } )
776
- . unwrap ( ) ;
777
- let schema_cache = SchemaCache :: load ( & conn) . await ;
778
- tx. send ( InternalMessage :: SetSchemaCache ( schema_cache) )
779
- . unwrap ( ) ;
780
- } ) ;
770
+ client
771
+ . send_notification :: < ShowMessage > ( ShowMessageParams {
772
+ typ : lsp_types:: MessageType :: INFO ,
773
+ message : "Refreshing schema cache..." . to_string ( ) ,
774
+ } )
775
+ . unwrap ( ) ;
776
+ let schema_cache = SchemaCache :: load ( & conn) . await ;
777
+ tx. send ( InternalMessage :: SetSchemaCache ( schema_cache) )
778
+ . unwrap ( ) ;
781
779
}
782
780
783
781
fn did_change_configuration (
You can’t perform that action at this time.
0 commit comments