diff --git a/libraries/navigation/nodes/Node.php b/libraries/navigation/nodes/Node.php index 424de281fb..5e8b68ab46 100644 --- a/libraries/navigation/nodes/Node.php +++ b/libraries/navigation/nodes/Node.php @@ -480,7 +480,7 @@ class Node $query = "SHOW DATABASES "; $query .= $this->_getWhereClause('Database', $searchClause); - $query .= " AND ("; + $query .= "AND ("; $subClauses = array(); foreach ($prefixes as $prefix) { $subClauses[] = " LOCATE('" @@ -741,7 +741,7 @@ class Node . " LIKE '" . $each_only_db . "' "; } - $whereClause .= implode("OR", $subClauses) . ")"; + $whereClause .= implode("OR", $subClauses) . ") "; } return $whereClause; diff --git a/test/classes/navigation/NodeTest.php b/test/classes/navigation/NodeTest.php index 6e92e52333..3ff85aa8f7 100644 --- a/test/classes/navigation/NodeTest.php +++ b/test/classes/navigation/NodeTest.php @@ -475,7 +475,7 @@ class NodeTest extends PHPUnit_Framework_TestCase $dbi->expects($this->once()) ->method('fetchResult') ->with( - "SHOW DATABASES WHERE TRUE AND (" + "SHOW DATABASES WHERE TRUE AND (" . " LOCATE('db_', CONCAT(`Database`, '_')) = 1" . " OR LOCATE('aa_', CONCAT(`Database`, '_')) = 1 )" );