Skip to content

Conversation

@kamil-tekiela
Copy link

@kamil-tekiela kamil-tekiela commented Oct 18, 2025

It seems that some time ago the named parameter feature was adjusted to cover for multiple keys. This place was missed and has been broken ever since.

@HLeithner This also covers the changes in #350. Both tests should still work after the references are removed.

@HLeithner
Copy link
Contributor

Thanks, I think nobody noticed this because no one is using the statement class directly and the database driver doesn't accept any variables on execute method.

Copy link
Contributor

@richard67 richard67 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review successful. It seems that place was forgotten with PR #303 . In the execute method it has made that change in the same way.

@richard67
Copy link
Contributor

I've successfully tested this PR by creating the table and running the code added by this PR here to the unit test.

Without this PR you get an error "Cannot access offset of type array on array", with line 309 of the MysqliStatement.php file at the top of the call stack, and the record is not inserted into the test table.

With this PR the record is inserted without any error.

@richard67 richard67 merged commit e56b182 into joomla-framework:3.x-dev Oct 26, 2025
33 checks passed
@richard67
Copy link
Contributor

Thanks.

@kamil-tekiela kamil-tekiela deleted the Fix-MysqliStatement-to-work-with-named-params branch October 26, 2025 12:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants