Skip to content

Commit 0ddf74c

Browse files
committed
chore: more linting fixes
1 parent 887ce89 commit 0ddf74c

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
@@ -124,21 +124,15 @@ export class BaseChat implements Chat {
124124
}
125125

126126
public sendChatUpdate(params: ChatUpdateParams) {
127-
this.connection
128-
.sendNotification(chatUpdateNotificationType.method, params)
129-
.then(() => {})
130-
.catch(() => {})
127+
return this.connection.sendNotification(chatUpdateNotificationType.method, params)
131128
}
132129

133130
public onFileClicked(handler: NotificationHandler<FileClickParams>) {
134131
this.connection.onNotification(fileClickNotificationType.method, handler)
135132
}
136133

137134
public sendContextCommands(params: ContextCommandParams) {
138-
this.connection
139-
.sendNotification(contextCommandsNotificationType.method, params)
140-
.then(() => {})
141-
.catch(() => {})
135+
return this.connection.sendNotification(contextCommandsNotificationType.method, params)
142136
}
143137

144138
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
@@ -145,7 +145,7 @@ export interface QuickActionCommand {
145145
}
146146

147147
export type ContextCommandIconType = 'file' | 'folder' | 'code-block' | 'list-add' | 'magic'
148-
export type IconType = 'ContextCommandIconType' | 'help' | 'trash' | 'search' | 'calendar'
148+
export type IconType = ContextCommandIconType | 'help' | 'trash' | 'search' | 'calendar' | string
149149

150150
/**
151151
* Configuration object for registering chat quick actions groups.

0 commit comments

Comments
 (0)