From e5b3ba3d9e916bfdbcb4e32d51f3b71857580016 Mon Sep 17 00:00:00 2001 From: Sam Carlton Date: Sun, 21 Aug 2022 08:45:04 -0500 Subject: [PATCH] Trim readFile error message --- helpers/scanner/file-api.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/helpers/scanner/file-api.js b/helpers/scanner/file-api.js index dbc1bc0..16450a6 100644 --- a/helpers/scanner/file-api.js +++ b/helpers/scanner/file-api.js @@ -299,7 +299,7 @@ export function FileReader () { function readFile(_file, format, encoding) { file = _file; if (!file || !file.name || !(file.path || file.stream || file.buffer)) { - throw new Error("cannot read as File: " + JSON.stringify(file)); + throw new Error("cannot read as File: " + JSON.stringify(file).slice(0, 1000)); } if (0 !== self.readyState) { console.log("already loading, request to change format ignored");