Skip to content

Commit c31ca83

Browse files
committed
Merge pull request jamierumbelow#142 from kamote/master
Using get_many or get_many_by produce duplicate deleted = 0
2 parents 7a1aa45 + 24c600f commit c31ca83

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

core/MY_Model.php

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -158,11 +158,6 @@ public function get_by()
158158
*/
159159
public function get_many($values)
160160
{
161-
if ($this->soft_delete && $this->_temporary_with_deleted !== TRUE)
162-
{
163-
$this->_database->where($this->soft_delete_key, (bool)$this->_temporary_only_deleted);
164-
}
165-
166161
$this->_database->where_in($this->primary_key, $values);
167162

168163
return $this->get_all();
@@ -174,12 +169,7 @@ public function get_many($values)
174169
public function get_many_by()
175170
{
176171
$where = func_get_args();
177-
178-
if ($this->soft_delete && $this->_temporary_with_deleted !== TRUE)
179-
{
180-
$this->_database->where($this->soft_delete_key, (bool)$this->_temporary_only_deleted);
181-
}
182-
172+
183173
$this->_set_where($where);
184174

185175
return $this->get_all();

0 commit comments

Comments
 (0)