Skip to content

Commit 43ba840

Browse files
committed
Use request constants
1 parent 701c029 commit 43ba840

File tree

2 files changed

+37
-36
lines changed

2 files changed

+37
-36
lines changed

package-lock.json

Lines changed: 35 additions & 35 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/workflow/languageServer.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import * as path from "path";
22
import * as vscode from "vscode";
33

44
import {Commands} from "@github/actions-languageserver/commands";
5+
import {ReadFileRequest, Requests} from "@github/actions-languageserver/request";
56
import {InitializationOptions, LogLevel} from "@github/actions-languageserver/initializationOptions";
67
import {BaseLanguageClient, LanguageClientOptions} from "vscode-languageclient";
78
import {LanguageClient as BrowserLanguageClient} from "vscode-languageclient/browser";
@@ -62,7 +63,7 @@ export async function initLanguageServer(context: vscode.ExtensionContext) {
6263
client = new BrowserLanguageClient("actions-language", "GitHub Actions Language Server", clientOptions, worker);
6364
}
6465

65-
client.onRequest("actions/readFile", async (event: {path: string}) => {
66+
client.onRequest(Requests.ReadFile, async (event: ReadFileRequest) => {
6667
if (typeof event?.path !== "string") {
6768
return null;
6869
}

0 commit comments

Comments
 (0)