mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-21 07:56:16 -04:00
import: introduce importMaxFileSize setting. Defaults to 50 MB
From Etherpad 1.8.3 onwards, the maximum allowed size for a single imported file will always be bounded. The maximum allowed size can be configured via importMaxFileSize.
This commit is contained in:
parent
d1ad29a3d1
commit
f4418149cb
4 changed files with 25 additions and 0 deletions
|
@ -72,6 +72,7 @@ async function doImport(req, res, padId)
|
|||
let form = new formidable.IncomingForm();
|
||||
form.keepExtensions = true;
|
||||
form.uploadDir = tmpDirectory;
|
||||
form.maxFileSize = settings.importMaxFileSize;
|
||||
|
||||
// locally wrapped Promise, since form.parse requires a callback
|
||||
let srcFile = await new Promise((resolve, reject) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue