minor tweak

This commit is contained in:
Reinaldo Neto 2023-02-08 20:11:30 -03:00
parent 05dca20e8d
commit a5eaca0bcc
1 changed files with 1 additions and 1 deletions

View File

@ -44,9 +44,9 @@ const addProtocol = (url: string): string => {
}; };
const openLink = async (url: string, theme: TSupportedThemes = 'light'): Promise<void> => { const openLink = async (url: string, theme: TSupportedThemes = 'light'): Promise<void> => {
url = addProtocol(url);
try { try {
const browser = UserPreferences.getString(DEFAULT_BROWSER_KEY); const browser = UserPreferences.getString(DEFAULT_BROWSER_KEY);
url = addProtocol(url);
if (browser === 'inApp') { if (browser === 'inApp') {
await WebBrowser.openBrowserAsync(url, { await WebBrowser.openBrowserAsync(url, {
toolbarColor: themes[theme].headerBackground, toolbarColor: themes[theme].headerBackground,