Skip to content

Commit bb158a1

Browse files
authored
refactor: Resolve analyzer info errors in Flutter SDK example (#909)
1 parent e097da5 commit bb158a1

File tree

1 file changed

+12
-7
lines changed
  • packages/flutter/example/lib/live_list

1 file changed

+12
-7
lines changed

packages/flutter/example/lib/live_list/main.dart

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,19 +49,24 @@ class _MyAppState extends State<MyApp> {
4949
height: double.infinity,
5050
alignment: Alignment.center,
5151
child: initFailed == null
52-
? Column(
53-
mainAxisAlignment: MainAxisAlignment.center,
54-
children: <Widget>[
55-
CircularProgressIndicator(),
56-
Text('Connecting to the server...'),
57-
],
58-
)
52+
? _buildLoading()
5953
: const Text('Connecting to the server failed!'),
6054
),
6155
),
6256
);
6357
}
6458

59+
Column _buildLoading() {
60+
// ignore: prefer_const_constructors
61+
return Column(
62+
mainAxisAlignment: MainAxisAlignment.center,
63+
children: const [
64+
CircularProgressIndicator(),
65+
Text('Connecting to the server...'),
66+
],
67+
);
68+
}
69+
6570
Future<bool> initData() async {
6671
await Parse().initialize(keyParseApplicationId, keyParseServerUrl,
6772
clientKey: keyParseClientKey,

0 commit comments

Comments
 (0)