-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Filemanager checks empty array 6.4.13 #3706
Labels
Comments
@matthewjohns0n this looks like PHP compatibility issue where |
The array wasn't null but it was zero length. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I upgraded an add-on which makes use of system/ee/legacy/libraries/Filemanager.php
The call to fetch_upload_dir_prefs() throws an error because the _upload_dir_prefs array has no elements in it.
This is the error:
The line to check for the empty array is currently:
I suggest changing this to:
So that it checks if there are any elements before it starts checking if a particular element exists. This stops an error being thrown.
See line 156 of system/ee/legacy/libraries/Filemanager.php
How To Reproduce
Using Reinos Single Sign On version v5.4.3
Error Messages
Screenshots / Videos / Template Code
Environment Details:
Possible Solution
in system/ee/legacy/libraries/Filemanager.php
public function fetch_upload_dir_prefs($dir_id, $ignore_site_id = false)
Additional context
The text was updated successfully, but these errors were encountered: