fix: remove hardcoded 6767 from app metadata and analytics fetch

This commit is contained in:
Nice Try
2026-06-26 15:48:39 +00:00
parent ae093a62bf
commit 0ed055b83b
2 changed files with 3 additions and 2 deletions
+2 -1
View File
@@ -43,8 +43,9 @@ interface AnalyticsData {
}
async function getAnalyticsData(): Promise<AnalyticsData> {
const res = await fetch('http://127.0.0.1:6767/api/progress?type=analytics', {
const res = await fetch('/api/progress?type=analytics', {
cache: 'no-store',
next: { tags: ['analytics'] },
})
if (!res.ok) {
throw new Error('Failed to fetch analytics')
+1 -1
View File
@@ -20,7 +20,7 @@ export const metadata: Metadata = {
openGraph: {
type: 'website',
locale: 'en_US',
url: 'http://localhost:6767',
url: process.env.NEXT_PUBLIC_APP_URL || 'http://localhost:6969',
siteName: 'OfflineAcademy',
title: 'OfflineAcademy — Your Personal Offline Learning Center',
description: 'A self-hosted, privacy-first learning platform for offline courses.',