modifyUserPermissions method

Future<List<Permission>> modifyUserPermissions(
  1. String sdkId,
  2. String userId,
  3. Permission permissions
)

Implementation

Future<List<Permission>> modifyUserPermissions(String sdkId, String userId, Permission permissions) async {
	final res = await _methodChannel.invokeMethod<String>(
		'PermissionApi.modifyUserPermissions',
		{
			"sdkId": sdkId,
			"userId": jsonEncode(userId),
			"permissions": jsonEncode(Permission.encode(permissions)),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method modifyUserPermissions");
	final parsedResJson = jsonDecode(res);
	return (parsedResJson as List<dynamic>).map((x1) => Permission.fromJSON(x1) ).toList();
}