summaryrefslogtreecommitdiffstats
path: root/core/js/public/comments.js
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2018-07-31 17:11:46 +0200
committerJoas Schilling <coding@schilljs.com>2018-07-31 17:11:46 +0200
commit3f45ab97da98e1d20f3fdebf639a17c161d0cec7 (patch)
treec6740c03a41b7f72c0eb787fcddad2535b3d4748 /core/js/public/comments.js
parent3e0668e348a3935b76c915b8aa1e523caf8da921 (diff)
downloadnextcloud-server-3f45ab97da98e1d20f3fdebf639a17c161d0cec7.tar.gz
nextcloud-server-3f45ab97da98e1d20f3fdebf639a17c161d0cec7.zip
Improve URL detection
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'core/js/public/comments.js')
-rw-r--r--core/js/public/comments.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/js/public/comments.js b/core/js/public/comments.js
index 9811528e4c1..f4825f08642 100644
--- a/core/js/public/comments.js
+++ b/core/js/public/comments.js
@@ -21,7 +21,7 @@
* The downside: anything not ascii is excluded. Not sure how common it is in areas using different
* alphabets… the upside: fake domains with similar looking characters won't be formatted as links
*/
- urlRegex: /(\s|^)(https?:\/\/)?((?:[-A-Z0-9+_]*\.)+[-A-Z]+(?:\/[-A-Z0-9+&@#%?=~_|!:,.;()]*)*)(\s|$)/ig,
+ urlRegex: /(\s|^)(https?:\/\/)?((?:[-A-Z0-9+_]+\.)+[-A-Z]+(?:\/[-A-Z0-9+&@#%?=~_|!:,.;()]*)*)(\s|$)/ig,
plainToRich: function(content) {
content = this.formatLinksRich(content);