fix: add /mobile prefix to all client-side fetch() calls for basePath
This commit is contained in:
@@ -87,7 +87,7 @@ export default function ForumPage() {
|
||||
|
||||
const fetchCategories = useCallback(async () => {
|
||||
try {
|
||||
const res = await fetch("/api/forum/categories");
|
||||
const res = await fetch("/mobile/api/forum/categories");
|
||||
const data = await res.json();
|
||||
if (res.ok) {
|
||||
setCategories(data.categories);
|
||||
@@ -159,7 +159,7 @@ export default function ForumPage() {
|
||||
setCreating(true);
|
||||
|
||||
try {
|
||||
const res = await fetch("/api/forum/threads", {
|
||||
const res = await fetch("/mobile/api/forum/threads", {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
|
||||
Reference in New Issue
Block a user