*/
public function count($table, array $condition = [], array $params = []): int
{
+ // @TODO Can we dump this to have ": int" as returned type-hint?
if (empty($table)) {
throw new InvalidArgumentException('Parameter "table" cannot be empty.');
}
$upds = implode(', ', $upd);
- $r = $this->e(sprintf("UPDATE %s SET %s;", $table_name, $upds));
+ $r = $this->e(sprintf("UPDATE %s SET %s;", DBA::quoteIdentifier($table_name), $upds));
if (!$this->isResult($r)) {
throw new \RuntimeException("Failed updating `$table_name`: " . $this->errorMessage());
}