fix: background upload, finish 7.0 translation support

This commit is contained in:
David Ralph
2022-06-05 15:43:49 +01:00
parent f413f4e31c
commit 7df77d33e4
14 changed files with 256 additions and 23 deletions

View File

@@ -23,7 +23,7 @@ export default class FileUpload extends PureComponent {
});
const settingsSize = new TextEncoder().encode(JSON.stringify(settings)).length;
if (videoCheck(file) === true) {
if (videoCheck(file.type) === true) {
if (settingsSize + file.size > 4850000) {
return toast(this.getMessage('toasts.no_storage'));
}
@@ -32,7 +32,7 @@ export default class FileUpload extends PureComponent {
}
// todo: change number
compressAccurately(file, 200).then(async (res) => {
compressAccurately(file, 300).then(async (res) => {
if (settingsSize + res.size > 4850000) {
return toast(this.getMessage('toasts.no_storage'));
}