From 8174a19ac00b4f3b1b1d012c3ee53982f0ac8897 Mon Sep 17 00:00:00 2001 From: Fabian Beer <32813692+madebyfabian@users.noreply.github.com> Date: Sat, 27 Jul 2019 08:59:02 +0200 Subject: [PATCH] Added leading slash in URL Same here, otherwise it will throw an error because it cant find the fetch URL path --- .../tutorial/04-logic/06-await-blocks/app-b/App.svelte | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/site/content/tutorial/04-logic/06-await-blocks/app-b/App.svelte b/site/content/tutorial/04-logic/06-await-blocks/app-b/App.svelte index 8c8036c0f1..a6d0346733 100644 --- a/site/content/tutorial/04-logic/06-await-blocks/app-b/App.svelte +++ b/site/content/tutorial/04-logic/06-await-blocks/app-b/App.svelte @@ -2,7 +2,7 @@ let promise = getRandomNumber(); async function getRandomNumber() { - const res = await fetch(`tutorial/random-number`); + const res = await fetch(`/tutorial/random-number`); const text = await res.text(); if (res.ok) { @@ -27,4 +27,4 @@

The number is {number}

{:catch error}

{error.message}

-{/await} \ No newline at end of file +{/await}