diff --git a/package-lock.json b/package-lock.json index 3711205..0a91bd5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "stemroller", - "version": "2.0.4", + "version": "2.0.5", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "stemroller", - "version": "2.0.4", + "version": "2.0.5", "license": "Unlicense", "dependencies": { "@distube/ytdl-core": "^4.13.3", diff --git a/package.json b/package.json index f95678c..e1685e1 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "stemroller", - "version": "2.0.4", + "version": "2.0.5", "private": true, "type": "module", "description": "Isolate vocals, drums, bass, and other instrumental stems from any song", diff --git a/renderer-src/components/SearchAndResults.svelte b/renderer-src/components/SearchAndResults.svelte index 0e71a75..f318cdd 100644 --- a/renderer-src/components/SearchAndResults.svelte +++ b/renderer-src/components/SearchAndResults.svelte @@ -21,10 +21,8 @@ const results = await window.youtubeSearch(query) if (results.videos.length > 0) { videos = results.videos - status = null - } else { - throw new Error('No video results available') } + status = null } catch (err) { console.error(err) status = { step: 'error' } @@ -84,6 +82,8 @@ {#each videos as video} {/each} + {:else if status === null && !videos?.length} +

No video results available.

{:else if status !== null && status.step === 'error'}

An error occurred. Please make sure you're connected to the internet and try again.

{:else if !hasQuery}