diff --git a/components/details/details-content.tsx b/components/details/details-content.tsx
index cd905e1..574b6bb 100644
--- a/components/details/details-content.tsx
+++ b/components/details/details-content.tsx
@@ -21,7 +21,7 @@ type Article = {
title: string;
}[];
files: {
- file_url: string;
+ fileUrl: string;
file_alt: string;
}[];
};
@@ -252,9 +252,9 @@ export default function DetailContent() {
- {articleDetail?.files?.[0]?.file_url ? (
+ {articleDetail?.files?.[0]?.fileUrl ? (
@@ -640,7 +638,7 @@ export default function EditArticleForm(props: { isDetail: boolean }) {
width={480}
height={360}
alt={`image-${index}`}
- src={file.file_url || "/default-avatar.png"}
+ src={file.fileUrl || "/default-avatar.png"}
className="h-[100px] object-cover w-[150px]"
/>
@@ -663,7 +661,7 @@ export default function EditArticleForm(props: { isDetail: boolean }) {
width={480}
height={360}
alt={`image-${index}`}
- src={file?.file_url || "/default-avatar.png"}
+ src={file?.fileUrl || "/default-avatar.png"}
className="h-[100px] object-cover w-[150px]"
/>
diff --git a/components/landing-page/header-latest.tsx b/components/landing-page/header-latest.tsx
index 580d7bb..382ea7e 100644
--- a/components/landing-page/header-latest.tsx
+++ b/components/landing-page/header-latest.tsx
@@ -16,7 +16,7 @@ type Article = {
title: string;
}[];
files: {
- file_url: string;
+ fileUrl: string;
file_alt: string;
}[];
};
diff --git a/components/landing-page/header.tsx b/components/landing-page/header.tsx
index 147f775..b512c5d 100644
--- a/components/landing-page/header.tsx
+++ b/components/landing-page/header.tsx
@@ -16,7 +16,7 @@ type Article = {
title: string;
}[];
files: {
- file_url: string;
+ fileUrl: string;
file_alt: string;
}[];
};
diff --git a/components/landing-page/news.tsx b/components/landing-page/news.tsx
index 384206d..c6f2c31 100644
--- a/components/landing-page/news.tsx
+++ b/components/landing-page/news.tsx
@@ -25,7 +25,7 @@ type Article = {
title: string;
}[];
files: {
- file_url: string;
+ fileUrl: string;
file_alt: string;
}[];
};
diff --git a/components/landing-page/opini.tsx b/components/landing-page/opini.tsx
index d7c4810..2af2780 100644
--- a/components/landing-page/opini.tsx
+++ b/components/landing-page/opini.tsx
@@ -16,7 +16,7 @@ type Article = {
title: string;
}[];
files: {
- file_url: string;
+ fileUrl: string;
file_alt: string;
}[];
};
diff --git a/components/landing-page/popular-news.tsx b/components/landing-page/popular-news.tsx
index cbddbbd..3c2e957 100644
--- a/components/landing-page/popular-news.tsx
+++ b/components/landing-page/popular-news.tsx
@@ -16,7 +16,7 @@ type Article = {
title: string;
}[];
files: {
- file_url: string;
+ fileUrl: string;
file_alt: string;
}[];
};
diff --git a/service/http-config/axios-base-instance.ts b/service/http-config/axios-base-instance.ts
index de3efbe..c4342d5 100644
--- a/service/http-config/axios-base-instance.ts
+++ b/service/http-config/axios-base-instance.ts
@@ -6,7 +6,7 @@ const axiosBaseInstance = axios.create({
baseURL,
headers: {
"Content-Type": "application/json",
- "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640"
+ "X-Client-Key": "e41eefe6-70da-4cb2-bf90-aa033fd082be",
},
});
diff --git a/service/http-config/axios-interceptor-instance.ts b/service/http-config/axios-interceptor-instance.ts
index 422a192..6cdcefd 100644
--- a/service/http-config/axios-interceptor-instance.ts
+++ b/service/http-config/axios-interceptor-instance.ts
@@ -10,7 +10,7 @@ const axiosInterceptorInstance = axios.create({
baseURL,
headers: {
"Content-Type": "application/json",
- "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640"
+ "X-Client-Key": "e41eefe6-70da-4cb2-bf90-aa033fd082be",
},
withCredentials: true,
});
diff --git a/service/http-config/http-base-services.ts b/service/http-config/http-base-services.ts
index 755d158..c4af37d 100644
--- a/service/http-config/http-base-services.ts
+++ b/service/http-config/http-base-services.ts
@@ -2,11 +2,11 @@ import axiosBaseInstance from "./axios-base-instance";
const defaultHeaders = {
"Content-Type": "application/json",
- "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640"
+ "X-Client-Key": "e41eefe6-70da-4cb2-bf90-aa033fd082be",
};
-export async function httpGet(pathUrl: any, headers?: any) {
- console.log("X-HEADERS : ", defaultHeaders)
+export async function httpGet(pathUrl: any, headers?: any) {
+ console.log("X-HEADERS : ", defaultHeaders);
const mergedHeaders = {
...defaultHeaders,
...headers,
diff --git a/service/http-config/http-interceptor-services.ts b/service/http-config/http-interceptor-services.ts
index 4d33d96..2f88d2b 100644
--- a/service/http-config/http-interceptor-services.ts
+++ b/service/http-config/http-interceptor-services.ts
@@ -5,11 +5,11 @@ import { getCsrfToken } from "../master-user";
const defaultHeaders = {
"Content-Type": "application/json",
- "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640"
+ "X-Client-Key": "e41eefe6-70da-4cb2-bf90-aa033fd082be",
};
export async function httpGetInterceptor(pathUrl: any) {
- console.log("X-HEADERS : ", defaultHeaders)
+ console.log("X-HEADERS : ", defaultHeaders);
const response = await axiosInterceptorInstance
.get(pathUrl, { headers: defaultHeaders })
.catch((error) => error.response);
@@ -35,7 +35,11 @@ export async function httpGetInterceptor(pathUrl: any) {
}
}
-export async function httpPostInterceptor(pathUrl: any, data: any, headers?: any) {
+export async function httpPostInterceptor(
+ pathUrl: any,
+ data: any,
+ headers?: any
+) {
const resCsrf = await getCsrfToken();
const csrfToken = resCsrf?.data?.csrf_token;
@@ -67,7 +71,11 @@ export async function httpPostInterceptor(pathUrl: any, data: any, headers?: any
}
}
-export async function httpPutInterceptor(pathUrl: any, data: any, headers?: any) {
+export async function httpPutInterceptor(
+ pathUrl: any,
+ data: any,
+ headers?: any
+) {
const resCsrf = await getCsrfToken();
const csrfToken = resCsrf?.data?.csrf_token;
@@ -99,7 +107,7 @@ export async function httpPutInterceptor(pathUrl: any, data: any, headers?: any)
}
export async function httpDeleteInterceptor(pathUrl: any, headers?: any) {
- const resCsrf = await getCsrfToken();
+ const resCsrf = await getCsrfToken();
const csrfToken = resCsrf?.data?.csrf_token;
const mergedHeaders = {