From a2fefc656095520b109a5061b4506420b27ffed5 Mon Sep 17 00:00:00 2001 From: Marcin Kurczewski Date: Fri, 17 Oct 2014 19:29:38 +0200 Subject: [PATCH] Fixed YET ANOTHER fpdo fuckup. This library sucks donkey's balls. --- src/Dao/AbstractDao.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Dao/AbstractDao.php b/src/Dao/AbstractDao.php index fa7179cb..348c378e 100644 --- a/src/Dao/AbstractDao.php +++ b/src/Dao/AbstractDao.php @@ -64,7 +64,7 @@ abstract class AbstractDao implements ICrudDao, IBatchDao public function findAll() { - $query = $this->fpdo->from($this->tableName); + $query = $this->fpdo->from($this->tableName)->disableSmartJoin(); $arrayEntities = iterator_to_array($query); return $this->arrayToEntities($arrayEntities); } @@ -151,7 +151,7 @@ abstract class AbstractDao implements ICrudDao, IBatchDao { if (is_array($value) and empty($value)) return []; - $query = $this->fpdo->from($this->tableName)->where($columnName, $value); + $query = $this->fpdo->from($this->tableName)->disableSmartJoin()->where($columnName, $value); $arrayEntities = iterator_to_array($query); return $this->arrayToEntities($arrayEntities); } @@ -170,7 +170,7 @@ abstract class AbstractDao implements ICrudDao, IBatchDao { $this->beforeDelete($entity); } - $this->fpdo->deleteFrom($this->tableName)->where($columnName, $value)->execute(); + $this->fpdo->deleteFrom($this->tableName)->disableSmartJoin()->where($columnName, $value)->execute(); } protected function afterLoad(Entity $entity)