You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// More typical upload method, the file data is in a multipart mime post.
4655
4657
for (var i in files.files) {
4656
-
var file = files.files[i], fpath = obj.path.join(xfile.fullpath, file.originalFilename);
4657
-
if (obj.common.IsFilenameValid(file.originalFilename) && ((xfile.quota == null) || ((totalsize + file.size) < xfile.quota))) { // Check if quota would not be broken if we add this file
var safeOriginalFilename = obj.path.basename(originalFilename);
4661
+
var isFilenameAcceptable = (safeOriginalFilename === originalFilename) && obj.common.IsFilenameValid(safeOriginalFilename);
4662
+
if (isFilenameAcceptable && ((xfile.quota == null) || ((totalsize + file.size) < xfile.quota))) { // Check if quota would not be broken if we add this file
4663
+
var fpath = obj.path.join(xfile.fullpath, safeOriginalFilename);
0 commit comments