getWifiIPv4 method

Future<String?> getWifiIPv4()

Returns the current Wi-Fi IPv4 address.

Implementation

Future<String?> getWifiIPv4() async {
  try {
    return await _networkInfo.getWifiIP();
  } on PlatformException catch (e) {
    throw PlatformException(
        code: 'Failed to get Wifi IPv4 address',
        message: e.message,
        details: e.details);
  }
}