mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-02-05 06:09:57 +01:00
updated modal to not show parentheses when max file size
is not defined... Also fixing hideAlerts error in ACP when opening the upload modal.
This commit is contained in:
@@ -113,8 +113,6 @@ define('admin/settings', ['uploader', 'sounds'], function(uploader, sounds) {
|
||||
uploader.open(uploadBtn.attr('data-route'), {}, 0, function(image) {
|
||||
$('#' + uploadBtn.attr('data-target')).val(image);
|
||||
});
|
||||
|
||||
uploader.hideAlerts();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
@@ -21,7 +21,7 @@ define('uploader', ['csrf'], function(csrf) {
|
||||
|
||||
if (fileSize) {
|
||||
uploadForm.find('#file-size-block')
|
||||
.translateText('[[uploads:maximum-file-size, ' + fileSize + ']]')
|
||||
.translateText('([[uploads:maximum-file-size, ' + fileSize + ']])')
|
||||
.removeClass('hide');
|
||||
} else {
|
||||
uploadForm.find('#file-size-block').addClass('hide');
|
||||
@@ -102,7 +102,7 @@ define('uploader', ['csrf'], function(csrf) {
|
||||
}
|
||||
|
||||
module.hideAlerts = function(modal) {
|
||||
modal.find('#alert-status, #alert-success, #alert-error, #upload-progress-box').addClass('hide');
|
||||
$(modal).find('#alert-status, #alert-success, #alert-error, #upload-progress-box').addClass('hide');
|
||||
};
|
||||
|
||||
return module;
|
||||
|
||||
Reference in New Issue
Block a user