diff --git a/html.ts b/html.ts
index a1e0256..c84fb36 100644
--- a/html.ts
+++ b/html.ts
@@ -129,7 +129,7 @@ export function profilePageHtml(profile: Profile, articles: Article[]): string {
return htmlLayout(title, body, profile);
}
-function openWithNostrAppHtml(bech32Id): string {
+function openWithNostrAppHtml(bech32Id: string): string {
let appLinksHtml = "";
const appLinks = [
{ title: "Habla", href: `https://habla.news/a/${bech32Id}` },
diff --git a/ldap.ts b/ldap.ts
index 1a74a67..d201430 100644
--- a/ldap.ts
+++ b/ldap.ts
@@ -4,7 +4,7 @@ import config from "./config.ts";
const { ldap, ldapEnabled } = config;
-let client;
+let client: Client;
if (ldapEnabled) {
client = new Client({ url: ldap.url });
}
diff --git a/server.ts b/server.ts
index 73914b9..c32e1dd 100644
--- a/server.ts
+++ b/server.ts
@@ -1,4 +1,4 @@
-import { Application, Router, send } from "@oak/oak";
+import { Application, Context, Router, send } from "@oak/oak";
import config from "./config.ts";
import naddrHandler from "./handlers/naddr.ts";
import nprofileHandler from "./handlers/nprofile.ts";
@@ -10,7 +10,7 @@ import notFoundHandler from "./handlers/not-found.ts";
const router = new Router();
-router.get("/:path", async (ctx: ctx) => {
+router.get("/:path", async (ctx: Context) => {
const { path } = ctx.params;
if (path.startsWith("naddr")) {
@@ -26,7 +26,7 @@ router.get("/:path", async (ctx: ctx) => {
}
});
-router.get("/:user/:kind.atom", async (ctx: ctx) => {
+router.get("/:user/:kind.atom", async (ctx: Context) => {
const { user, kind } = ctx.params;
if (
@@ -39,7 +39,7 @@ router.get("/:user/:kind.atom", async (ctx: ctx) => {
}
});
-router.get("/:user/:identifier", async (ctx: ctx) => {
+router.get("/:user/:identifier", async (ctx: Context) => {
const { user } = ctx.params;
if (user.startsWith("@") || user.startsWith("~")) {
@@ -51,7 +51,7 @@ router.get("/:user/:identifier", async (ctx: ctx) => {
router.get("/assets/:path*", async (ctx) => {
try {
- const filePath = ctx.params.path;
+ const filePath = ctx.params.path || '';
await send(ctx, filePath, {
root: `${Deno.cwd()}/assets`,