From f8cff89de2ef165748362cf0f104e2bf7bf88618 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Sat, 18 Jul 2020 22:27:48 +0200 Subject: Fileview.. --- src/handler/fileView.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/handler/fileView.ts') diff --git a/src/handler/fileView.ts b/src/handler/fileView.ts index 90c7176..eb9c3a1 100644 --- a/src/handler/fileView.ts +++ b/src/handler/fileView.ts @@ -1,6 +1,6 @@ import type { HandlerFunc, Context } from "https://deno.land/x/abc@master/mod.ts"; -import { cleanPath } from "../util/files.ts"; +import { getFiles } from "../util/files.ts"; export const handlePath: HandlerFunc = async (c: Context) => { - return await c.render("./src/views/index.html", { path: cleanPath(c.path) }); + return await c.render("./src/views/index.html", { files: await getFiles(c.path) }); }; -- cgit v1.2.3