#371 closed defect (bug) (fixed)
Test for upload enabled in every iteration of loop
| Reported by: | nickromney | Owned by: | matt |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Administration | Version: | |
| Severity: | trivial | Keywords: | |
| Cc: | Focuses: |
Description
In wp-admin/menu.php, in the foreach ($menu as $item) loop, lines 56-59 test for the upload condition.
It would be easier to test for it when specifying the array in line 17:
Replace:
$menu[45] = array(('Upload'), get_settings('fileupload_minlevel'), 'upload.php');
with:
if ((get_settings('use_fileupload') && ($user_level >= get_settings('fileupload_minlevel')))) {
$menu[45] = array(('Upload'), get_settings('fileupload_minlevel'), 'upload.php');
}
Change History (2)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Good idea.