fix: properly parse titles

This commit is contained in:
xananax prozaxx 2022-06-28 11:09:06 +02:00
parent b03ddcb428
commit b4fd4f344c

View File

@ -237,7 +237,7 @@
.then((response) => response.text())
.then(wait)
.then((text) => {
const [, title] = text.match(/^(#\s\w+)/) ||
const [, title] = text.match(/^#\s+(\w+.+)/) ||
text.match(/(.*?)\n===+/m) || [, path];
document.title = `${title} | ${mainTitle}`;
if (params.has("source")) {