diff --git a/.fvmrc b/.fvmrc new file mode 100644 index 0000000000000000000000000000000000000000..0fdcb48769cb981b5f80ce221d26be4851a96db9 --- /dev/null +++ b/.fvmrc @@ -0,0 +1,3 @@ +{ + "flutter": "3.27.1" +} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 47b734680d1c85bdbdabc0d51b1420d4ca05f830..4bfd4fbc97b13e8c027c3708bfaf43b7b8f55f75 100644 --- a/.gitignore +++ b/.gitignore @@ -54,4 +54,7 @@ integration_test/duniter/data/chains/ # Ignore PC deps scripts/pushGecko -android-old \ No newline at end of file +android-old + +# FVM Version Cache +.fvm/ \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000000000000000000000000000000000000..b01430d59d44c3313c7c6dddc2bd3bfe9ab0542d --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "dart.flutterSdkPath": ".fvm/versions/3.27.1" +} \ No newline at end of file diff --git a/lib/providers/my_wallets.dart b/lib/providers/my_wallets.dart index 404b89bc4b7fb4c0feb4c7dcf08ead7650aed704..5dc55227bdcfb35d51e0bcd7582633748b8b8bc4 100644 --- a/lib/providers/my_wallets.dart +++ b/lib/providers/my_wallets.dart @@ -14,8 +14,6 @@ import 'package:provider/provider.dart'; class MyWalletsProvider with ChangeNotifier { List<WalletData> listWallets = []; - WalletData? idtyWallet; - List<WalletData> listWalletsWithoutIdty = []; String pinCode = ''; late String mnemonic; int? pinLenght; @@ -37,6 +35,10 @@ class MyWalletsProvider with ChangeNotifier { bool isWalletsExists() => chestBox.isNotEmpty; + WalletData? get idtyWallet => listWallets.firstWhereOrNull((w) => w.isMembre) ?? listWallets.firstWhereOrNull((w) => w.hasIdentity); + + List<WalletData> get listWalletsWithoutIdty => listWallets.where((w) => !w.hasIdentity).toList(); + Future<List<WalletData>> readAllWallets([int? chest]) async { final sub = Provider.of<SubstrateSdk>(homeContext, listen: false); chest = chest ?? getCurrentChest(); @@ -66,11 +68,6 @@ class MyWalletsProvider with ChangeNotifier { listWallets.sort((p1, p2) => Comparable.compare(p1.number!, p2.number!)); - idtyWallet = listWallets.firstWhereOrNull((w) => w.hasIdentity); - - listWalletsWithoutIdty = listWallets.toList(); - listWalletsWithoutIdty.removeWhere((w) => w.address == idtyWallet?.address); - return listWallets; } diff --git a/pubspec.yaml b/pubspec.yaml index fd1fe0f254b33188718eb2d99475bf8a927d9fc0..8d2e566568ac8118b6b114d733abfa757f669fff 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -2,7 +2,7 @@ name: gecko description: Pay with G1. publish_to: "none" -version: 0.1.21+95 +version: 0.1.21+96 environment: sdk: ^3.5.3