Skip to content

Commit

Permalink
fix: update api ip address in fetchData.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
maxitect committed Nov 23, 2024
1 parent 2dd1c9e commit 6ee3fb2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/utils/fetchData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,14 @@ export async function fetchData(
body?: string
): Promise<any> {
try {
const response = await fetch(`http://34.105.229.117:8080/${query}`, {
const response = await fetch(`http://34.160.33.103/${query}`, {
method,
headers: {
"Content-Type": "application/json",
},
...(body && { body }),
});

// Check if the response is OK before parsing as JSON
if (!response.ok) {
console.error("HTTP error:", response.status, response.statusText);
throw new Error(`HTTP error! Status: ${response.status}`);
Expand Down

0 comments on commit 6ee3fb2

Please sign in to comment.