vscode-objectscript icon indicating copy to clipboard operation
vscode-objectscript copied to clipboard

Uncaught errors reported when no workspace is open

Open isc-bsaviano opened this issue 1 year ago • 2 comments

    The uncaught errors are coming from here, which I'm pretty sure is unrelated to this PR:

https://github.com/intersystems-community/vscode-objectscript/blob/225df7689c499c792174464f3f2f04bf8da74a8a/src/utils/index.ts#L364-L369

Originally posted by @isc-bsaviano in https://github.com/intersystems-community/vscode-objectscript/issues/1003#issuecomment-1292594921

isc-bsaviano avatar Oct 26 '22 20:10 isc-bsaviano

@gjsjohnmurray This function is called in a lot of places so any fix for this would be pretty invasive. IMO the right thing to do is to return undefined here instead of throwing and to check for the undefined wherever this is called

isc-bsaviano avatar Oct 26 '22 20:10 isc-bsaviano

@isc-bsaviano I agree.

gjsjohnmurray avatar Oct 27 '22 20:10 gjsjohnmurray