consistency checks fixes

This commit is contained in:
zadam
2020-07-01 22:42:59 +02:00
parent f0b608ddec
commit 78a2c1753e
4 changed files with 43 additions and 39 deletions

View File

@@ -158,7 +158,8 @@ function getContentDisposition(filename) {
const STRING_MIME_TYPES = ["application/x-javascript", "image/svg+xml"];
function isStringNote(type, mime) {
return ["text", "code", "relation-map", "search"].includes(type)
// render and book are string note in the sense that they are expected to contain empty string
return ["text", "code", "relation-map", "search", "render", "book"].includes(type)
|| mime.startsWith('text/')
|| STRING_MIME_TYPES.includes(mime);
}