diff --git a/src/lib/config.js b/src/lib/config.js index 4335536..ba0a39d 100644 --- a/src/lib/config.js +++ b/src/lib/config.js @@ -1,3 +1,3 @@ export const config = { - api_url: "http://api.omersabic.com:3001" + api_url: "http://localhost:3000" } \ No newline at end of file diff --git a/src/routes/(app)/articles/editArticleDialog.svelte b/src/routes/(app)/articles/editArticleDialog.svelte index 04cfb91..57990ef 100644 --- a/src/routes/(app)/articles/editArticleDialog.svelte +++ b/src/routes/(app)/articles/editArticleDialog.svelte @@ -44,7 +44,7 @@
- +
diff --git a/src/routes/site/[site_id]/[article_id]/+page.server.js b/src/routes/site/[site_id]/[article_id]/+page.server.js index 3d5f7ba..9a9a2b8 100644 --- a/src/routes/site/[site_id]/[article_id]/+page.server.js +++ b/src/routes/site/[site_id]/[article_id]/+page.server.js @@ -4,7 +4,7 @@ import { articles } from "../store"; /** @type {import("./$types").PageServerLoad} */ export async function load(event) { - const result = await fetch(config.api_url + "/blog/article?id=" + event.params.article_id).then(x=>x.json()); + const result = await fetch(config.api_url + "/blog/article?slug=" + event.params.article_id).then(x=>x.json()); if(!result.article) error(404)