paragonie/easydb

weird error using EasyDB

Closed this issue · 2 comments

I have all the debugging stuff in PHP turned on so if there are ever notices, even, it spews into logs.

Today, this showed up, which is very interesting to me. I did not know easydb uses guzzle? Elsewhere in my project guzzle is used (dependency of another library in use). This is a fresh composer install of EasyDB, which composer tells me is v2.11.0

Recoverable fatal error: Object of class GuzzleHttp\Psr7\Response could not be converted to string in /path/to/app/includes/vendor/paragonie/easydb/src/EasyDB.php on line 1005

EasyDB doesn't.

easydb/composer.json

Lines 48 to 58 in 38cfac4

"require": {
"php": "^7|^8",
"ext-pdo": "*",
"paragonie/corner": "^1|^2"
},
"require-dev": {
"phpunit/phpunit": "^6|^7",
"psalm/plugin-phpunit": "<1",
"squizlabs/php_codesniffer": "^3",
"vimeo/psalm": "^3"
},

It's more than likely that something is passing a Response object to an EasyDB method and it's being passed to PDOStatement::execute().

$stmt->execute($params);

Ah! OK, thank you.

somewhere I am calling a database and my argument is not what it seems