Skip to content

Commit

Permalink
updated middleware URL
Browse files Browse the repository at this point in the history
  • Loading branch information
arinkulshi-skylight committed Dec 12, 2024
1 parent 040a1c6 commit f198c5c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions frontend/api/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ import {
} from "./types/types";

const apiUrl = import.meta.env.VITE_API_URL || "http://localhost:8000/";
const middlewareURL =
import.meta.env.VITE_MIDDLEWARE_URL || "http://localhost:8000/";
const middlewareURL = import.meta.env.MIDDLEWARE_API_URL || "http://localhost:8000/";

export const AlignImage = async (
args: AlignImageArgs,
Expand Down Expand Up @@ -45,7 +44,7 @@ export const ImageToText = async (
labels: JSON.stringify(fieldNames),
});

const imageToTextURL = `${apiUrl}image_to_text/`;
const imageToTextURL = `${middlewareURL}/api/image_file_to_text/`;
try {
const response = await fetch(imageToTextURL, {
method: "POST",
Expand Down

0 comments on commit f198c5c

Please sign in to comment.