mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-23 12:09:43 +00:00
22 lines
656 B
Dart
22 lines
656 B
Dart
|
import 'package:cw_core/crypto_currency.dart';
|
||
|
|
||
|
class SolanaTransactionCreationException implements Exception {
|
||
|
final String exceptionMessage;
|
||
|
|
||
|
SolanaTransactionCreationException(CryptoCurrency currency)
|
||
|
: exceptionMessage = 'Error creating ${currency.title} transaction.';
|
||
|
|
||
|
@override
|
||
|
String toString() => exceptionMessage;
|
||
|
}
|
||
|
|
||
|
class SolanaTransactionWrongBalanceException implements Exception {
|
||
|
final String exceptionMessage;
|
||
|
|
||
|
SolanaTransactionWrongBalanceException(CryptoCurrency currency)
|
||
|
: exceptionMessage = 'Wrong balance. Not enough ${currency.title} on your balance.';
|
||
|
|
||
|
@override
|
||
|
String toString() => exceptionMessage;
|
||
|
}
|