mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-05-07 15:45:54 +02:00
backport crash fix if there are no files #6515
This commit is contained in:
committed by
GitHub
parent
f2011aafac
commit
12337302a7
@@ -76,7 +76,7 @@ uploadsController.get = function (req, res, next) {
|
||||
|
||||
res.render('admin/manage/uploads', {
|
||||
currentFolder: currentFolder.replace(nconf.get('upload_path'), ''),
|
||||
showPids: files[0].hasOwnProperty('inPids'),
|
||||
showPids: files.length && files[0].hasOwnProperty('inPids'),
|
||||
files: files,
|
||||
breadcrumbs: buildBreadcrumbs(currentFolder),
|
||||
pagination: pagination.create(page, Math.ceil(itemCount / itemsPerPage), req.query),
|
||||
|
||||
Reference in New Issue
Block a user