vscode: remove type assertion

This commit is contained in:
Veetaha 2020-02-24 21:23:48 +02:00
parent b4db089a6b
commit af57251c31
2 changed files with 3 additions and 2 deletions

View file

@ -32,6 +32,7 @@ module.exports = {
"@typescript-eslint/semi": [ "@typescript-eslint/semi": [
"error", "error",
"always" "always"
] ],
"@typescript-eslint/no-unnecessary-type-assertion": "error"
} }
}; };

View file

@ -63,7 +63,7 @@ export async function ensureServerBinary(source: null | BinarySource): Promise<n
async function downloadServer(source: BinarySource.GithubRelease): Promise<boolean> { async function downloadServer(source: BinarySource.GithubRelease): Promise<boolean> {
try { try {
const releaseInfo = (await fetchArtifactReleaseInfo(source.repo, source.file, source.version))!; const releaseInfo = await fetchArtifactReleaseInfo(source.repo, source.file, source.version);
await downloadArtifact(releaseInfo, source.file, source.dir, "language server"); await downloadArtifact(releaseInfo, source.file, source.dir, "language server");
await setServerVersion(source.storage, releaseInfo.releaseName); await setServerVersion(source.storage, releaseInfo.releaseName);