deleteUsers method

Future<bool> deleteUsers(
  1. List<String> users
)

This operation deletes users on a device. The device shall support deletion of device users and their credentials through the DeleteUsers command. A device may have one or more fixed users that cannot be deleted to ensure access to the unit. Either all users are deleted successfully or a fault message shall be returned and no users be deleted.

Implementation

Future<bool> deleteUsers(List<String> users) async {
  loggy.debug('deleteUsers');

  final envelope = await transport.sendRequest(
      uri,
      transport
          .securedEnvelope(soap.DeviceManagementRequest.deleteUsers(users)));

  if (envelope.body.hasFault) {
    throw Exception(envelope.body.fault.toString());
  }

  return true;
}