Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion src/routes/(console)/(migration-wizard)/resource-form.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
}

let error = false;
let errorMessage = '';
let isOpen = false;
let report: Models.MigrationReport;

Expand Down Expand Up @@ -86,6 +87,13 @@
} catch (e) {
if (!isOpen) return;
error = true;
errorMessage =
typeof e === 'object' &&
e !== null &&
'message' in e &&
typeof e.message === 'string'
? e.message
: '';
}

isOpen = false;
Expand Down Expand Up @@ -141,7 +149,9 @@
<Layout.Stack gap="l">
{#if error}
<Alert.Inline status="error" title="Couldn’t load resources">
{#if migrationType === 'provider'}
{#if errorMessage}
{errorMessage}
{:else if migrationType === 'provider'}
Please double-check your credentials from the previous step and try again.
{:else}
The API key required for the migration may no longer be valid or has expired, please
Expand Down
Loading