❌ Removed a funky route from the frontend API
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
import router from "../router";
|
||||
import { Request, Response } from "express";
|
||||
import axios from "axios";
|
||||
import { IMPORT_SERVICE_BASE_URI } from "../../../client/constants/endpoints";
|
||||
|
||||
router.route("/getComicCovers").post(async (req: Request, res: Response) => {
|
||||
typeof req.body === "object" ? req.body : {};
|
||||
const importServiceURI = process.env.DOCKER_HOST
|
||||
? `http://${process.env.DOCKER_HOST}:3000/api/import`
|
||||
: "http://localhost:3000/api/import";
|
||||
await axios.request({
|
||||
url: `${IMPORT_SERVICE_BASE_URI}/processAndImportToDB`,
|
||||
url: `${importServiceURI}/processAndImportToDB`,
|
||||
method: "POST",
|
||||
data: {
|
||||
extractionOptions: req.body.extractionOptions,
|
||||
|
||||
Reference in New Issue
Block a user