mirror of
https://github.com/laurent22/joplin.git
synced 2025-01-26 18:58:21 +02:00
Android: Fix crash on opening settings on old versions of Android (#10793)
This commit is contained in:
parent
39ad1e23a8
commit
60e347a782
@ -7,10 +7,11 @@ import { _ } from '@joplin/lib/locale';
|
|||||||
|
|
||||||
const getWebViewVersionText = () => {
|
const getWebViewVersionText = () => {
|
||||||
if (Platform.OS === 'android') {
|
if (Platform.OS === 'android') {
|
||||||
const constants = NativeModules.SystemVersionInformationModule.getConstants();
|
// SystemVersionInformationModule is unavailable on older versions of Android.
|
||||||
|
const constants = NativeModules.SystemVersionInformationModule?.getConstants();
|
||||||
return [
|
return [
|
||||||
_('WebView version: %s', constants.webViewVersion),
|
_('WebView version: %s', constants?.webViewVersion ?? _('Unknown')),
|
||||||
_('WebView package: %s', constants.webViewPackage),
|
_('WebView package: %s', constants?.webViewPackage ?? _('Unknown')),
|
||||||
].join('\n');
|
].join('\n');
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user