diagnostic (#1027)

Co-authored-by: Drew Ansbacher <drew.ansbacher@spiredigital.com>
This commit is contained in:
Drew Ansbacher
2022-01-07 13:15:48 -07:00
committed by Aiden McClelland
parent 1a63c61ae2
commit d3b95405db
2 changed files with 4 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
<ion-content>
<div style="padding: 48px">
<ng-container *ngIf="!restarted && !forgotten; else refresh">
<ng-container *ngIf="!restarted; else refresh">
<h1 class="ion-text-center" style="padding-bottom: 36px; font-size: calc(2vw + 14px);">EmbassyOS - Diagnostic Mode</h1>
<h2 style="padding-bottom: 16px; font-size: calc(1vw + 14px); font-weight: bold;">EmbassyOS launch error:</h2>
<div class="code-block">
@@ -18,7 +18,7 @@
</ion-button>
<div *ngIf="error.code === 15 || error.code === 25" class="ion-padding-top">
<ion-button *ngIf="error.code === 15" (click)="forgetDrive()">
{{ error.code === 15 ? 'Use Current Drive' : 'Enter Recovery Mode' }}
{{ error.code === 15 ? 'Setup Current Drive' : 'Enter Recovery Mode' }}
</ion-button>
</div>
</ng-container>

View File

@@ -15,7 +15,6 @@ export class HomePage {
} = { } as any
solutions: string[] = []
restarted = false
forgotten = false
constructor (
private readonly loadingCtrl: LoadingController,
@@ -84,7 +83,8 @@ export class HomePage {
try {
await this.api.forgetDrive()
this.forgotten = true
await this.api.restart()
this.restarted = true
} catch (e) {
console.error(e)
} finally {