Skip to content

Commit

Permalink
Refresh for Elastica\Index::flush implemented #316
Browse files Browse the repository at this point in the history
  • Loading branch information
ruflin committed May 18, 2013
1 parent 5365894 commit fffe6a4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions changes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ CHANGES
- Elastica\Index::exists fixed for 0.90.0. HEAD request method introduced
- Elastica\Filter\AbstractMulti::getFilters() added
- Implement Elastica\Type\Mapping::enableAllField
- Refresh for Elastica\Index::flush implemented #316

2013-04-23
- Removed Elastica\Exception\AbstractException
Expand Down
5 changes: 2 additions & 3 deletions lib/Elastica/Index.php
Original file line number Diff line number Diff line change
Expand Up @@ -370,11 +370,10 @@ public function clearCache()
* @return \Elastica\Response Response object
* @link http://www.elasticsearch.org/guide/reference/api/admin-indices-flush.html
*/
public function flush()
public function flush($refresh = false)
{
$path = '_flush';
// TODO: Add option for refresh
return $this->request($path, Request::POST);
return $this->request($path, Request::POST, array(), array('refresh' => $refresh));
}

/**
Expand Down

0 comments on commit fffe6a4

Please sign in to comment.