mirror of
https://github.com/dg/dibi.git
synced 2025-02-24 10:53:17 +01:00
DibiFluent: added removeClause()
This commit is contained in:
parent
b9ec3047b0
commit
76c02a65da
@ -175,7 +175,8 @@ class DibiFluent extends DibiObject implements IDataSource
|
||||
{
|
||||
$this->cursor = & $this->clauses[self::_formatClause($clause)];
|
||||
|
||||
if ($remove) {
|
||||
if ($remove) { // deprecated, use removeClause
|
||||
trigger_error(__METHOD__ . '(..., TRUE) is deprecated; use removeClause() instead.', E_USER_NOTICE);
|
||||
$this->cursor = NULL;
|
||||
|
||||
} elseif ($this->cursor === NULL) {
|
||||
@ -187,6 +188,19 @@ class DibiFluent extends DibiObject implements IDataSource
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Removes a clause.
|
||||
* @param string clause name
|
||||
* @return DibiFluent provides a fluent interface
|
||||
*/
|
||||
public function removeClause($clause)
|
||||
{
|
||||
$this->clauses[self::_formatClause($clause)] = NULL;
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Change a SQL flag.
|
||||
* @param string flag name
|
||||
|
Loading…
x
Reference in New Issue
Block a user