Skip to content

Commit db1cca7

Browse files
committed
Lint TypeScript
1 parent 85c7702 commit db1cca7

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

main.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env -S deno run --import-map vendor/import_map.json --allow-net --allow-read=. --allow-write=refresh_tokens.json --allow-run=chroot/jail --check
22

3-
import { Deferred, deferred } from "https://deno.land/std@0.136.0/async/mod.ts";
3+
import { deferred } from "https://deno.land/std@0.136.0/async/mod.ts";
44
import { Status, serve } from "https://deno.land/std@0.136.0/http/mod.ts";
55
import { BufReader } from "https://deno.land/std@0.136.0/io/mod.ts";
66
import { basename } from "https://deno.land/std@0.136.0/path/mod.ts";
@@ -19,7 +19,7 @@ const tokenToPort: {[_: string]: number} = {};
1919
async function handler(request: Request): Promise<Response> {
2020
const url = new URL(request.url);
2121

22-
let token = request.headers.get("Cookie")?.split(", ").find(function(each) {
22+
const token = request.headers.get("Cookie")?.split(", ").find(function(each) {
2323
return each.startsWith("vscode-tkn=");
2424
})?.split("=")[1] ?? url.searchParams.get("tkn");
2525
if(token && Object.hasOwn(tokenToPort, token))

refresh_tokens.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { mutex } from "./mutex.ts";
44
export const BACKING_FILE = "refresh_tokens.json";
55

66
let tokens: {[_: string]: string} | null = null;
7-
let lock = mutex();
7+
const lock = mutex();
88

99
export async function getToken(username: string): Promise<string | null> {
1010
if(!tokens)

0 commit comments

Comments
 (0)