Skip to content

Commit

Permalink
Merge pull request #29 from filbertkm/queryexec
Browse files Browse the repository at this point in the history
Fix decoding of QueryExecuter response
  • Loading branch information
Benestar committed Jan 21, 2016
2 parents 69a1582 + 97fdea5 commit 5a1e0a4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/QueryExecuter.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public function execute( $query ) {
}

$result = $this->getResult( $query );
return $result['search'];
return $result['results'];
}

private function getResult( $query ) {
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/QueryExecuterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ private function getHttpMock( $params ) {
$this->equalTo( 'test.example.com' ),
$this->equalTo( $params )
)
->will( $this->returnValue( '{"search":"~=[,,_,,]:3"}' ) );
->will( $this->returnValue( '{"results":"~=[,,_,,]:3"}' ) );

return $http;
}
Expand Down

0 comments on commit 5a1e0a4

Please sign in to comment.