quote sql query parameters when writing to the debug log
This commit is contained in:
committed by
Frédéric Guillot
parent
87432a4f34
commit
a69709b305
@@ -269,13 +269,13 @@ class StatementHandler
|
||||
|
||||
foreach ($this->positionalParams as $value) {
|
||||
$pdoStatement->bindValue($i, $value, PDO::PARAM_STR);
|
||||
$this->db->setLogMessage("param[$i]: $value");
|
||||
$this->db->setLogMessage("param[$i]: '$value'");
|
||||
$i++;
|
||||
}
|
||||
|
||||
foreach ($this->namedParams as $name => $value) {
|
||||
$pdoStatement->bindValue($name, $value, PDO::PARAM_STR);
|
||||
$this->db->setLogMessage("param[$name]: $value");
|
||||
$this->db->setLogMessage("param[$name]: '$value'");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user