diff options
Diffstat (limited to 'app/Models/DatabaseDAOSQLite.php')
| -rw-r--r-- | app/Models/DatabaseDAOSQLite.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/Models/DatabaseDAOSQLite.php b/app/Models/DatabaseDAOSQLite.php index 9380df094..231616f49 100644 --- a/app/Models/DatabaseDAOSQLite.php +++ b/app/Models/DatabaseDAOSQLite.php @@ -10,7 +10,7 @@ class FreshRSS_DatabaseDAOSQLite extends FreshRSS_DatabaseDAO { public function tablesAreCorrect(): bool { $sql = "SELECT name FROM sqlite_master WHERE type='table'"; $stm = $this->pdo->query($sql); - $res = $stm ? $stm->fetchAll(PDO::FETCH_ASSOC) : false; + $res = $stm !== false ? $stm->fetchAll(PDO::FETCH_ASSOC) : false; if ($res === false) { return false; } @@ -35,7 +35,7 @@ class FreshRSS_DatabaseDAOSQLite extends FreshRSS_DatabaseDAO { public function getSchema(string $table): array { $sql = 'PRAGMA table_info(' . $table . ')'; $stm = $this->pdo->query($sql); - return $stm ? $this->listDaoToSchema($stm->fetchAll(PDO::FETCH_ASSOC) ?: []) : []; + return $stm !== false ? $this->listDaoToSchema($stm->fetchAll(PDO::FETCH_ASSOC) ?: []) : []; } #[\Override] |
