Fixes for build
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -8,4 +8,5 @@ devtools_options.yaml
|
|||||||
untranslated.txt
|
untranslated.txt
|
||||||
generate_protos.sh
|
generate_protos.sh
|
||||||
update_dep.sh
|
update_dep.sh
|
||||||
.vscode/
|
.vscode/
|
||||||
|
GeneratedPluginRegistrant.swift
|
||||||
@@ -17,14 +17,12 @@ class AccountLoader extends StatelessWidget {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) => Consumer<AccountProvider>(builder: (context, provider, _) {
|
Widget build(BuildContext context) => Consumer<AccountProvider>(builder: (context, provider, _) {
|
||||||
if (provider.account != null) return child;
|
if (provider.account != null) {
|
||||||
|
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||||
if (!provider.restoreAttempted) {
|
});
|
||||||
WidgetsBinding.instance.addPostFrameCallback((_) => provider.restoreIfPossible());
|
return child;
|
||||||
return const Center(child: CircularProgressIndicator());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (provider.isLoading) return const Center(child: CircularProgressIndicator());
|
|
||||||
if (provider.error != null) {
|
if (provider.error != null) {
|
||||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||||
postNotifyUserOfErrorX(
|
postNotifyUserOfErrorX(
|
||||||
|
|||||||
Reference in New Issue
Block a user