hasReadPhoneStatePermission method

  1. @override
Future<bool> hasReadPhoneStatePermission()
override

Checks if device has read phone state permission

Android only

Implementation

@override
Future<bool> hasReadPhoneStatePermission() {
  if (defaultTargetPlatform != TargetPlatform.android) {
    return Future.value(true);
  }
  return _channel.invokeMethod<bool?>('hasReadPhoneStatePermission', {}).then<bool>((bool? value) => value ?? false);
}