forked from TheWrightServer/ProxmoxVE
Fix API path in category fetch calls by removing leading slash
This commit is contained in:
parent
1a412bce38
commit
2f9f51ec7c
@ -48,7 +48,7 @@ function ScriptContent() {
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
fetch(
|
fetch(
|
||||||
`/api/categories?_=${process.env.NEXT_PUBLIC_BUILD_TIME || Date.now()}`,
|
`api/categories?_=${process.env.NEXT_PUBLIC_BUILD_TIME || Date.now()}`,
|
||||||
)
|
)
|
||||||
.then((response) => response.json())
|
.then((response) => response.json())
|
||||||
.then((categories) => {
|
.then((categories) => {
|
||||||
|
@ -53,7 +53,7 @@ export default function CommandMenu() {
|
|||||||
const fetchCategories = async () => {
|
const fetchCategories = async () => {
|
||||||
setIsLoading(true);
|
setIsLoading(true);
|
||||||
fetch(
|
fetch(
|
||||||
`/api/categories?_=${process.env.NEXT_PUBLIC_BUILD_TIME || Date.now()}`,
|
`api/categories?_=${process.env.NEXT_PUBLIC_BUILD_TIME || Date.now()}`,
|
||||||
)
|
)
|
||||||
.then((response) => response.json())
|
.then((response) => response.json())
|
||||||
.then((categories) => {
|
.then((categories) => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user