Skip to content

Commit 46a486d

Browse files
committed
chore: remove redundant types
1 parent eb1cc74 commit 46a486d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/adapters/command-execution-adapter.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { LanguageClientConnection } from "../main";
44
export type CommandCustomCallbackFunction = (command: ExecuteCommandParams) => Promise<any | void>;
55

66
export default class CommandExecutionAdapter {
7-
private static commandsCustomCallbacks: Map<string, CommandCustomCallbackFunction> = new Map<string, CommandCustomCallbackFunction>();
7+
private static commandsCustomCallbacks = new Map<string, CommandCustomCallbackFunction>();
88

99
public static canAdapt(serverCapabilities: ServerCapabilities): boolean {
1010
return serverCapabilities.executeCommandProvider != null;
@@ -14,14 +14,14 @@ export default class CommandExecutionAdapter {
1414
this.commandsCustomCallbacks.set(command, callback);
1515
}
1616

17-
public static async executeCommand(connection: LanguageClientConnection, command: string, commandArgs?: any[] | undefined): Promise<any | void> {
17+
public static async executeCommand(connection: LanguageClientConnection, command: string, commandArgs?: any[]): Promise<any | void> {
1818
const executeCommandParams = CommandExecutionAdapter.createExecuteCommandParams(command, commandArgs);
1919
const commandCustomCallback = this.commandsCustomCallbacks.get(command);
2020

2121
return commandCustomCallback != null ? await commandCustomCallback(executeCommandParams) : await connection.executeCommand(executeCommandParams);
2222
}
2323

24-
private static createExecuteCommandParams(command: string, commandArgs?: any[] | undefined): ExecuteCommandParams {
24+
private static createExecuteCommandParams(command: string, commandArgs?: any[]): ExecuteCommandParams {
2525
return {
2626
command: command,
2727
arguments: commandArgs

0 commit comments

Comments
 (0)