refactor(backend): split log files into separate file
This commit is contained in:
@ -5,7 +5,7 @@ import { AccessDeniedError, BadRequestError } from "@lib/errors.ts";
|
||||
import { createStreamResponse, isValidUrl } from "@lib/helpers.ts";
|
||||
import * as openai from "@lib/openai.ts";
|
||||
import tds from "https://cdn.skypack.dev/turndown@7.2.0";
|
||||
import { createLogger } from "@lib/log.ts";
|
||||
import { createLogger } from "@lib/log/index.ts";
|
||||
import { createRecipe, Recipe } from "@lib/resource/recipes.ts";
|
||||
import recipeSchema from "@lib/recipeSchema.ts";
|
||||
import { fileExtension } from "https://deno.land/x/file_extension@v2.1.0/mod.ts";
|
||||
@ -136,8 +136,8 @@ async function processCreateRecipeFromUrl(
|
||||
const jsonLds = Array.from(
|
||||
document?.querySelectorAll(
|
||||
"script[type='application/ld+json']",
|
||||
) as HTMLScriptElement[],
|
||||
);
|
||||
),
|
||||
) as unknown as HTMLScriptElement[];
|
||||
|
||||
let recipe: z.infer<typeof recipeSchema> | undefined = undefined;
|
||||
if (jsonLds.length > 0) {
|
||||
|
Reference in New Issue
Block a user