fix: do not fail widget request after #exit
This commit is contained in:
parent
87a6dd56b8
commit
9bfbabb9df
1 changed files with 1 additions and 1 deletions
|
|
@ -145,7 +145,7 @@ def getWidgets (args : Lean.Lsp.Position) : RequestM (RequestTask (GetWidgetsRes
|
|||
let doc ← readDoc
|
||||
let filemap := doc.meta.text
|
||||
let pos := filemap.lspPosToUtf8Pos args
|
||||
withWaitFindSnapAtPos args fun snap => do
|
||||
withWaitFindSnap doc (·.endPos >= pos) (notFoundX := return ⟨∅⟩) fun snap => do
|
||||
let env := snap.env
|
||||
let ws := widgetInfosAt? filemap snap.infoTree pos
|
||||
let ws ← ws.toArray.mapM (fun (w : UserWidgetInfo) => do
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue