From 288ed04ccc30b58373576dc3be811aee43e67034 Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Fri, 31 Mar 2023 08:23:39 +0200 Subject: PHPStan level 6 for all PDO and Exception classes (#5239) * PHPStan level 6 for all PDO and Exception classes Contributes to https://github.com/FreshRSS/FreshRSS/issues/4112 * Fix type * Now also our remaining own librairies * Motivation for a few more files * A few more DAO classes * Last interface --- app/Models/DatabaseDAOSQLite.php | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'app/Models/DatabaseDAOSQLite.php') diff --git a/app/Models/DatabaseDAOSQLite.php b/app/Models/DatabaseDAOSQLite.php index e5a6f5a04..3fab1134d 100644 --- a/app/Models/DatabaseDAOSQLite.php +++ b/app/Models/DatabaseDAOSQLite.php @@ -25,6 +25,7 @@ class FreshRSS_DatabaseDAOSQLite extends FreshRSS_DatabaseDAO { return count(array_keys($tables, true, true)) == count($tables); } + /** @return array> */ public function getSchema(string $table): array { $sql = 'PRAGMA table_info(' . $table . ')'; $stm = $this->pdo->query($sql); @@ -45,6 +46,10 @@ class FreshRSS_DatabaseDAOSQLite extends FreshRSS_DatabaseDAO { )); } + /** + * @param array $dao + * @return array + */ public function daoToSchema(array $dao): array { return [ 'name' => $dao['name'], -- cgit v1.2.3