From a23eec55e82096a7c91bb873f6cf72106a9af1f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sa=C3=BAl=20Ibarra=20Corretg=C3=A9?= Date: Mon, 15 Jan 2018 14:21:50 +0100 Subject: [PATCH] [RN] Strip spaces when parsing URLs --- react/features/base/util/uri.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/react/features/base/util/uri.js b/react/features/base/util/uri.js index 2022a4170..e12e7fd02 100644 --- a/react/features/base/util/uri.js +++ b/react/features/base/util/uri.js @@ -177,6 +177,9 @@ export function parseStandardURIString(str: string) { let regex; let match: Array | null; + // cleanup spaces + str = str.replace(/\s/g, ''); + // protocol regex = new RegExp(`^${_URI_PROTOCOL_PATTERN}`, 'gi'); match = regex.exec(str);