Skip to content

Commit

Permalink
Removing extra parens from Comparisson expression builder
Browse files Browse the repository at this point in the history
  • Loading branch information
lorenzo committed Jun 11, 2013
1 parent b907196 commit 819643a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/Cake/Database/Expression/Comparison.php
Expand Up @@ -65,10 +65,9 @@ public function placeholder($token) {

public function sql() {
$value = $this->_value;
$template = '%s %s (%s)';
$template = '%s %s %s';
if (!($this->_value instanceof ExpressionInterface)) {
$value = $this->_bindValue($this->_field, $value, $this->_type);
$template = '%s %s %s';
}

return sprintf($template, $this->_field, $this->_conjunction, $value);
Expand Down

0 comments on commit 819643a

Please sign in to comment.