better error lsp server (#1850)
Signed-off-by: Jess Frazelle <github@jessfraz.com>
This commit is contained in:
@ -33,10 +33,12 @@ export default class Server {
|
||||
this.#fromServer,
|
||||
fileSystemManager
|
||||
)
|
||||
if (type_ === 'copilot') {
|
||||
if (!token || token === '') {
|
||||
throw new Error('auth token is required for copilot')
|
||||
throw new Error(
|
||||
type_ + ': auth token is required for lsp server to start'
|
||||
)
|
||||
}
|
||||
if (type_ === 'copilot') {
|
||||
await copilotLspRun(config, token)
|
||||
} else if (type_ === 'kcl') {
|
||||
await kclLspRun(config, token || '')
|
||||
|
Reference in New Issue
Block a user