ui: markdown: 使用非贪婪匹配

This commit is contained in:
undefined committed 2021-06-13 11:40:47 +08:00
1 parent d53b5d5a32
commit 6e06a27f2f
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "hydrooj",
"version": "2.28.32",
"version": "2.28.33",
"bin": "bin/hydrooj.js",
"main": "dist/loader.js",
"typings": "dist/loader.d.ts",
@@ -30,7 +30,7 @@ function mfrParser(url) {
const match = url.match(mfrRegex);
return match ? match[1] : url;
}
const EMBED_REGEX = /@\[([a-zA-Z].+)]\((.*?)[)]/im;
const EMBED_REGEX = /@\[([a-zA-Z].+?)]\((.*?)[)]/im;
function extractVideoParameters(url) {
const parameterMap = new Map();
const params = url.replace(/&/gi, '&').split(/[#?&]/);