+3
-4
@@ -1,5 +1,4 @@
|
||||
import { RouteConfig } from "$fresh/server.ts";
|
||||
import { Handlers } from "$fresh/server.ts";
|
||||
import type { Handlers, RouteConfig } from "@fresh/core";
|
||||
import { format, parse } from "$std/semver/mod.ts";
|
||||
import VERSIONS from "../../versions.json" with { type: "json" };
|
||||
import { extname } from "$std/path/mod.ts";
|
||||
@@ -17,8 +16,8 @@ const contentTypes = new Map([
|
||||
]);
|
||||
|
||||
export const handler: Handlers = {
|
||||
async GET(req, ctx) {
|
||||
const accept = req.headers.get("Accept");
|
||||
async GET(ctx) {
|
||||
const accept = ctx.req.headers.get("Accept");
|
||||
const isHTML = accept?.includes("text/html");
|
||||
const { version, path } = ctx.params;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user