getValueFromManifestOrInfoPlist method
Implementation
@override
Future<String> getValueFromManifestOrInfoPlist({String? androidManifestKey, String? iOSPlistKey}) async {
String? val = "";
try {
if (Platform.isAndroid) {
val = await mirrorFlyMethodChannel.invokeMethod('getManifestValue', {'key': androidManifestKey});
LogMessage.d('getValueFromManifestOrInfoPlist Android', ' $val');
return val ?? "";
} else if (Platform.isIOS) {
val = await mirrorFlyMethodChannel.invokeMethod('getPlistValue', {'key': iOSPlistKey});
LogMessage.d('getValueFromManifestOrInfoPlist iOS', ' $val');
return val ?? "";
} else {
return val;
}
} on PlatformException catch (e) {
LogMessage.d("Platform Exception =", " $e");
rethrow;
} on Exception catch (error) {
LogMessage.d("Exception ", " $error");
rethrow;
}
}