Skip to content

Commit

Permalink
Fixed bug where filter SQL was invalid.
Browse files Browse the repository at this point in the history
  • Loading branch information
Rowan Lewis committed Oct 1, 2009
1 parent d22e261 commit 5e2cbeb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions fields/field.expression.php
Expand Up @@ -210,6 +210,8 @@ public function prepareTableValue($data, XMLElement $link = null) {
-------------------------------------------------------------------------*/

public function buildDSRetrivalSQL($data, &$joins, &$where, $and = false) {
header('content-type: text/plain');

if (is_array($data)) {
if ($and) $data = implode('+', $data);
else $data = implode(',', $data);
Expand All @@ -232,6 +234,8 @@ public function buildDSRetrivalSQL($data, &$joins, &$where, $and = false) {
$entries[] = $row['entry_id'];
}

if (empty($entries)) return false;

$this->_key++;
$data = implode(", ", $entries);
$joins .= "
Expand Down

0 comments on commit 5e2cbeb

Please sign in to comment.