Skip to content

Commit 1ccb3af

Browse files
committed
chore: more linting fixes
1 parent efbf8d8 commit 1ccb3af

File tree

4 files changed

+9
-11
lines changed

4 files changed

+9
-11
lines changed

.eslintrc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ module.exports = {
2828
'@typescript-eslint/no-non-null-assertion': 'error',
2929
'@typescript-eslint/no-unsafe-assignment': 'off',
3030
'@typescript-eslint/no-unsafe-member-access': 'off',
31-
'@typescript-eslint/no-redundant-type-constituents': 'error',
31+
'@typescript-eslint/no-redundant-type-constituents': 'warn',
3232
'@typescript-eslint/unbound-method': 'error',
3333
'@typescript-eslint/no-misused-promises': 'warn',
3434
'@typescript-eslint/no-unsafe-return': 'off',

runtimes/runtimes/chat/baseChat.ts

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -144,21 +144,15 @@ export class BaseChat implements Chat {
144144
}
145145

146146
public sendChatUpdate(params: ChatUpdateParams) {
147-
this.connection
148-
.sendNotification(chatUpdateNotificationType.method, params)
149-
.then(() => {})
150-
.catch(() => {})
147+
return this.connection.sendNotification(chatUpdateNotificationType.method, params)
151148
}
152149

153150
public onFileClicked(handler: NotificationHandler<FileClickParams>) {
154151
this.connection.onNotification(fileClickNotificationType.method, handler)
155152
}
156153

157154
public sendContextCommands(params: ContextCommandParams) {
158-
this.connection
159-
.sendNotification(contextCommandsNotificationType.method, params)
160-
.then(() => {})
161-
.catch(() => {})
155+
return this.connection.sendNotification(contextCommandsNotificationType.method, params)
162156
}
163157

164158
public onCreatePrompt(handler: NotificationHandler<CreatePromptParams>) {

runtimes/runtimes/lsp/router/lspRouter.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,11 @@ ${JSON.stringify({ ...result.capabilities, ...result.awsServerCapabilities })}`
170170
this.lspConnection.client
171171
.register(DidChangeConfigurationNotification.type, undefined)
172172
.then(() => {})
173-
.catch(() => {})
173+
.catch(e => {
174+
this.lspConnection.console.error(
175+
`Failed to register DidChangeConfigurationNotification: ${e.message}`
176+
)
177+
})
174178
}
175179

176180
this.routeNotificationToAllServers((server, params) => server.sendInitializedNotification(params), params)

types/chat.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ export interface QuickActionCommand {
188188
}
189189

190190
export type ContextCommandIconType = 'file' | 'folder' | 'code-block' | 'list-add' | 'magic'
191-
export type IconType = 'ContextCommandIconType' | 'help' | 'trash' | 'search' | 'calendar'
191+
export type IconType = ContextCommandIconType | 'help' | 'trash' | 'search' | 'calendar' | string
192192

193193
/**
194194
* Configuration object for registering chat quick actions groups.

0 commit comments

Comments
 (0)