Browse Source

Fix errors

master
Gaëtan Renaudeau 7 years ago
parent
commit
34b30c5681
  1. 2
      src/components/TranslatedError.js
  2. 9
      static/i18n/en/errors.yml
  3. 13
      static/i18n/fr/errors.yml

2
src/components/TranslatedError.js

@ -24,7 +24,7 @@ class TranslatedError extends PureComponent<Props> {
return translation
}
logger.warn('TranslatedError: no transation!', error.name, error)
return error.message || error.name || ''
return error.message || error.name || t('errors:generic')
}
}

9
static/i18n/en/errors.yml

@ -1,7 +1,8 @@
RangeError: {{message}}
Error: {{message}}
LedgerAPIErrorWithMessage: {{message}}
TransportStatusError: {{message}}
generic: An error occurred
RangeError: '{{message}}'
Error: '{{message}}'
LedgerAPIErrorWithMessage: '{{message}}'
TransportStatusError: '{{message}}'
FeeEstimationFailed: 'fee estimation failed (status: {{status}})'
NotEnoughBalance: 'Not enough balance'
BtcUnmatchedApp: 'You must open application ‘{{currencyName}}’ on the device'

13
static/i18n/fr/errors.yml

@ -1,12 +1,9 @@
---
RangeError:
- message
Error:
- message
LedgerAPIErrorWithMessage:
- message
TransportStatusError:
- message
generic: An error occurred
RangeError: '{{message}}'
Error: '{{message}}'
LedgerAPIErrorWithMessage: '{{message}}'
TransportStatusError: '{{message}}'
FeeEstimationFailed: 'fee estimation failed (status: {{status}})'
NotEnoughBalance: 'Not enough balance'
BtcUnmatchedApp: 'You must open application ‘{{currencyName}}’ on the device'

Loading…
Cancel
Save