unacceptAddressOnTCPPort method
Reverses the acceptance ("unaccept") of an address
on a specified TCP port
.
address
: The IP address or hostname to unaccept.port
: The TCP port from which the address will be unaccepted. Ifnull
will remove from all ports.
Returns:
- A
Future<bool>
indicating whether the operation was successful.
Implementation
Future<bool> unacceptAddressOnTCPPort(String address, int? port) async {
address = address.trim();
if (address.isEmpty) return false;
var response = await _sendCommand("unaccept $address $port");
return response?.contains('true') ?? false;
}