Browse Source
Merge pull request #874 from gre/ManagerUnexpected
Drop error called ManagerUnexpectedError
master
Gaëtan Renaudeau
7 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
2 additions and
7 deletions
-
src/helpers/apps/installApp.js
-
src/helpers/apps/uninstallApp.js
-
static/i18n/en/errors.yml
|
|
@ -9,7 +9,6 @@ import type { LedgerScriptParams } from 'helpers/common' |
|
|
|
|
|
|
|
import { createCustomErrorClass } from '../errors' |
|
|
|
|
|
|
|
const ManagerUnexpectedError = createCustomErrorClass('ManagerUnexpected') |
|
|
|
const ManagerNotEnoughSpaceError = createCustomErrorClass('ManagerNotEnoughSpace') |
|
|
|
const ManagerDeviceLockedError = createCustomErrorClass('ManagerDeviceLocked') |
|
|
|
const ManagerAppAlreadyInstalledError = createCustomErrorClass('ManagerAppAlreadyInstalled') |
|
|
@ -27,7 +26,7 @@ function remapError(promise) { |
|
|
|
case e.message.endsWith('6a83'): |
|
|
|
throw new ManagerAppRelyOnBTCError() |
|
|
|
default: |
|
|
|
throw new ManagerUnexpectedError(e.message, { msg: e.message }) |
|
|
|
throw e |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
@ -8,7 +8,6 @@ import { createDeviceSocket } from 'helpers/socket' |
|
|
|
import type { LedgerScriptParams } from 'helpers/common' |
|
|
|
import { createCustomErrorClass } from '../errors' |
|
|
|
|
|
|
|
const ManagerUnexpectedError = createCustomErrorClass('ManagerUnexpectedError') |
|
|
|
const ManagerDeviceLockedError = createCustomErrorClass('ManagerDeviceLocked') |
|
|
|
const ManagerUninstallBTCDep = createCustomErrorClass('ManagerUninstallBTCDep') |
|
|
|
|
|
|
@ -20,7 +19,7 @@ function remapError(promise) { |
|
|
|
case e.message.endsWith('6a83'): |
|
|
|
throw new ManagerUninstallBTCDep() |
|
|
|
default: |
|
|
|
throw new ManagerUnexpectedError(e.message, { msg: e.message }) |
|
|
|
throw e |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
@ -65,9 +65,6 @@ ManagerDeviceLocked: |
|
|
|
ManagerNotEnoughSpace: |
|
|
|
title: Sorry, insufficient device storage |
|
|
|
description: Uninstall some apps to increase available storage and try again. |
|
|
|
ManagerUnexpected: |
|
|
|
title: That's unexpected ({{msg}}) #(Manager: {{msg}}) |
|
|
|
description: Please try again. |
|
|
|
ManagerUninstallBTCDep: |
|
|
|
title: Sorry, Bitcoin is required # include {{currencyName}} |
|
|
|
description: First uninstall apps that depend on Bitcoin. |
|
|
|