-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
68431fb
commit 05997d7
Showing
41 changed files
with
547 additions
and
1,193 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/// SPDX-License-Identifier: AGPL-3.0-or-later | ||
import 'dart:async'; | ||
|
||
import 'package:aewallet/application/account/accounts_notifier.dart'; | ||
import 'package:aewallet/model/data/account.dart'; | ||
import 'package:flutter_riverpod/flutter_riverpod.dart'; | ||
import 'package:riverpod_annotation/riverpod_annotation.dart'; | ||
|
||
part 'accounts.g.dart'; | ||
|
||
@riverpod | ||
Future<Account?> accountWithGenesisAddress( | ||
Ref ref, | ||
String genesisAddress, | ||
) async { | ||
final accounts = await ref.watch(accountsNotifierProvider.future); | ||
return accounts.getAccountWithGenesisAddress(genesisAddress); | ||
} | ||
|
||
@riverpod | ||
Future<Account?> accountWithName( | ||
Ref ref, | ||
String nameAccount, | ||
) async { | ||
final accounts = await ref.watch(accountsNotifierProvider.future); | ||
return accounts.getAccountWithName(nameAccount); | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.