Skip to content
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

Update dispatcher.php #277

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

petekelly
Copy link
Contributor

the require() on line 270 makes calls to mi_command() which passes the $errors variable by reference.

This then gets passed all over the place and is expected to be an array, not a string.

Array initialisation on line 269 is required because $errors is defined as a string previously, this causes a type error when you try to load the dispatcher page:

PHP Fatal error: Uncaught Error: [] operator not supported for strings

the require() on line 270 makes calls to mi_command() which passes the $errors variable by reference.

This then gets passed all over the place and is expected to be an array, not a string. 

Array initialisation on line 269 is required because $errors is defined as a string previously, this causes a type error when you try to load the dispatcher page:

PHP Fatal error:  Uncaught Error: [] operator not supported for strings
@petekelly
Copy link
Contributor Author

@liviuchircu any chance this could be merged?

@liviuchircu liviuchircu self-assigned this Jul 14, 2023
@liviuchircu
Copy link
Member

Hey, @petekelly! Good catch there. Still, won't your fix cause issues a couple lines below, due to the string concatenation bit which your patch now breaks (😊), possibly with PHP errors resembling:

PHP Notice:  Array to string conversion in test.php on line 6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants