20240406#2

This commit is contained in:
User committed 2024-04-06 01:43:19 +03:00
1 parent c681de9bfb
commit 6caceefc17
2 files changed
+3 -2

No files matched your search

+2 -1
View File
@@ -135,8 +135,9 @@ class MysqlStorage implements MysqlStorageInterface {
}
/** @inheritDoc */
public function findOne(string $sql) : array {
public function findOne(string $sql) : bool|array {
$result = $this->query($sql);
if (!$result || $result->num_rows == 0) return false;
$data = new MysqlStorageData($result);
return $data->fetchOne();
}
+1 -1
View File
@@ -86,7 +86,7 @@ interface MysqlStorageInterface {
* @param string $sql
* @return array
*/
public function findOne(string $sql) : array;
public function findOne(string $sql) : bool|array;
/**
* Метод экранирования данных с учетом текущего подключения в т.ч для LIKE