refactor: Added and applied require_trailing_commas linter rule

This commit is contained in:
Malin Errenst 2023-03-02 10:57:52 +01:00
commit ec7acc5385
112 changed files with 3466 additions and 2855 deletions

View file

@ -32,14 +32,15 @@ class SettingsStoriesController extends State<SettingsStories> {
final blockList = room.client.storiesBlockList;
blockList.add(user.id);
await showFutureLoadingDialog(
context: context,
future: () async {
await user.kick();
await room.client.setStoriesBlockList(blockList.toSet().toList());
setState(() {
users[user] = false;
});
context: context,
future: () async {
await user.kick();
await room.client.setStoriesBlockList(blockList.toSet().toList());
setState(() {
users[user] = false;
});
},
);
return;
}
@ -47,14 +48,15 @@ class SettingsStoriesController extends State<SettingsStories> {
final blockList = room.client.storiesBlockList;
blockList.remove(user.id);
await showFutureLoadingDialog(
context: context,
future: () async {
await room.client.setStoriesBlockList(blockList);
await room.invite(user.id);
setState(() {
users[user] = true;
});
context: context,
future: () async {
await room.client.setStoriesBlockList(blockList);
await room.invite(user.id);
setState(() {
users[user] = true;
});
},
);
return;
}

View file

@ -38,9 +38,10 @@ class SettingsStoriesView extends StatelessWidget {
}
if (snapshot.connectionState != ConnectionState.done) {
return const Center(
child: CircularProgressIndicator.adaptive(
strokeWidth: 2,
));
child: CircularProgressIndicator.adaptive(
strokeWidth: 2,
),
);
}
return ListView.builder(
itemCount: controller.users.length,