Merge pull request #88 from cosmocode/bot/autofix

🤖 Automatic code style fixes
This commit is contained in:
Andreas Gohr
2024-03-05 08:57:51 +01:00
committed by GitHub
2 changed files with 2 additions and 7 deletions

View File

@ -245,9 +245,7 @@ class SQLiteDB
*/
public function saveRecord($table, $data, $replace = true)
{
$columns = array_map(function ($column) {
return '"' . $column . '"';
}, array_keys($data));
$columns = array_map(static fn($column) => '"' . $column . '"', array_keys($data));
$values = array_values($data);
$placeholders = array_pad([], count($columns), '?');

View File

@ -158,11 +158,8 @@ class helper_plugin_sqlite extends Plugin
*
* @param string ...$args - the arguments of query(), the first is the sql and others are values
*/
public function query()
public function query(...$args)
{
// get function arguments
$args = func_get_args();
// clear the cache
$this->data = null;