Enable DFX for polygon wallet (#1267)

This commit is contained in:
Omar Hatem
2024-01-23 01:53:20 +02:00
committed by GitHub
parent 1b65adce53
commit d83054eded
2 changed files with 15 additions and 4 deletions
+5
View File
@@ -46,6 +46,8 @@ class DFXBuyProvider extends BuyProvider {
return 'XMR';
case WalletType.ethereum:
return 'ETH';
case WalletType.polygon:
return 'MATIC';
default:
throw Exception("WalletType is not available for DFX ${wallet.type}");
}
@@ -61,6 +63,8 @@ class DFXBuyProvider extends BuyProvider {
return 'Monero';
case WalletType.ethereum:
return 'Ethereum';
case WalletType.polygon:
return 'Polygon';
default:
throw Exception("WalletType is not available for DFX ${wallet.type}");
}
@@ -141,6 +145,7 @@ class DFXBuyProvider extends BuyProvider {
String getSignature(String message) {
switch (wallet.type) {
case WalletType.ethereum:
case WalletType.polygon:
return wallet.signMessage(message);
case WalletType.monero:
case WalletType.litecoin: