This commit is contained in:
xmflsct 2023-01-22 18:17:57 +01:00
parent 5cd83ae055
commit 613cf1365c
1 changed files with 5 additions and 4 deletions

View File

@ -73,18 +73,19 @@ const openLink = async (url: string, navigation?: any) => {
}
}
// Some links might end with an empty space at the end that triggers an error
switch (getGlobalStorage.string('app.browser')) {
// Some links might end with an empty space at the end that triggers an error
case 'external':
await Linking.openURL(url.trim())
break
case 'internal':
default:
await WebBrowser.openBrowserAsync(url.trim(), {
dismissButtonStyle: 'close',
enableBarCollapsing: true,
...(await browserPackage())
})
break
case 'external':
await Linking.openURL(url.trim())
break
}
}