Merge pull request #3130 from lkk214/fix/symbols-for-file
fix: Add context/getSymbolsForFiles endpoint in JetBrains and handle …
This commit is contained in:
commit
f9d2aee6ba
2 changed files with 7 additions and 1 deletions
|
|
@ -290,7 +290,12 @@ export async function getSymbolsForManyFiles(
|
|||
const filesAndSymbols = await Promise.all(
|
||||
uris.map(async (uri): Promise<[string, SymbolWithRange[]]> => {
|
||||
const contents = await ide.readFile(uri);
|
||||
const symbols = await getSymbolsForFile(uri, contents);
|
||||
let symbols = undefined;
|
||||
try {
|
||||
symbols = await getSymbolsForFile(uri, contents);
|
||||
} catch (e) {
|
||||
console.error(`Failed to get symbols for ${uri}:`, e);
|
||||
}
|
||||
return [uri, symbols ?? []];
|
||||
}),
|
||||
);
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ class ContinueBrowser(val project: Project, url: String) {
|
|||
"config/listProfiles",
|
||||
"profiles/switch",
|
||||
"didChangeSelectedProfile",
|
||||
"context/getSymbolsForFiles",
|
||||
)
|
||||
|
||||
private fun registerAppSchemeHandler() {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue