sendUserToAppStore method
void
sendUserToAppStore()
Implementation
void sendUserToAppStore() async {
if (_appStoreListingURL == null || _appStoreListingURL!.isEmpty) {
if (debugLogging) {
if (kDebugMode) {
print('hcUpgrade: empty _appStoreListingURL');
}
}
return;
}
if (debugLogging) {
if (kDebugMode) {
print('hcUpgrade: launching: $_appStoreListingURL');
}
}
if (await canLaunchUrl(Uri.parse(_appStoreListingURL!))) {
try {
await launchUrl(Uri.parse(_appStoreListingURL!),
mode: upgradeOS.isAndroid
? LaunchMode.externalNonBrowserApplication
: LaunchMode.platformDefault);
} catch (e) {
if (debugLogging) {
if (kDebugMode) {
print('hcUpgrade: launch to app store failed: $e');
}
}
}
} else {}
}