1
0
mirror of https://gitlab.com/comunic/comunicmobile synced 2025-06-19 08:15:16 +00:00

Start to build group settings screen

This commit is contained in:
2020-05-01 15:12:55 +02:00
parent 0bb9be9a72
commit 257523b526
4 changed files with 111 additions and 1 deletions

View File

@ -177,6 +177,21 @@ class GroupsHelper {
}
}
/// Get group settings
///
/// This function is currently a kind of alias, but it might
/// change in the future
///
/// Throws in case of error
Future<AdvancedGroupInfo> getSettings(int groupID) async {
final groupInfo = await getAdvancedInfo(groupID);
if (groupInfo.status != GetAdvancedInfoStatus.SUCCESS)
throw Exception("Could not get group information!");
return groupInfo.info;
}
/// Turn an API entry into a group object
Group _getGroupFromAPI(Map<String, dynamic> map) {
return Group(