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

db_connect $query param changed to $allow_bail = true bool #188

Open
kkmuffme opened this issue Jan 8, 2025 · 1 comment · May be fixed by #194
Open

db_connect $query param changed to $allow_bail = true bool #188

kkmuffme opened this issue Jan 8, 2025 · 1 comment · May be fixed by #194

Comments

@kkmuffme
Copy link
Contributor

kkmuffme commented Jan 8, 2025

https://github.com/stuttter/ludicrousdb/blob/master/ludicrousdb/includes/class-ludicrousdb.php#L692

public function db_connect( $query = '' ) {

vs WP core since 3.9.0
https://github.com/WordPress/wordpress-develop/blob/trunk/src/wp-includes/class-wpdb.php#L1948

public function db_connect( $allow_bail = true ) {

This leads to unexpected behavior and a PHP notice when ludicrousdb is used as drop-in, since plulgins might pass bool explicitly.

@kkmuffme
Copy link
Contributor Author

kkmuffme commented Jan 8, 2025

Similar (just rename) for:

  • $dbh_or_table in public function select( $db, $dbh_or_table = false ) {
  • public function _real_escape( $to_escape = '' ) {
  • $die_on_disconnect in public function check_connection( $die_on_disconnect = true

kkmuffme added a commit to kkmuffme/ludicrousdb that referenced this issue Jan 8, 2025
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 a pull request may close this issue.

1 participant