core: fix problem_files handle

This commit is contained in:
undefined committed 2021-11-10 12:59:36 +08:00
1 parent 39300f26e5
commit aac478f787
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -324,7 +324,7 @@ export class ProblemDetailHandler extends ProblemHandler {
const info = str.match(/\(file:\/\/(.+?)\)/);
return `(./${this.pdoc.docId}/file/${info[1]}${info[1].includes('?') ? '&' : '?'}tid=${args[1]})`;
})
.replace(/="file:\/\//g, (str) => {
.replace(/="file:\/\/(.+?)"/g, (str) => {
const info = str.match(/="file:\/\/(.+?)"/);
return `="./${this.pdoc.docId}/file/${info[1]}${info[1].includes('?') ? '&' : '?'}tid=${args[1]}"`;
});