aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2018-03-13 09:27:11 +0100
committerRoeland Jago Douma <roeland@famdouma.nl>2018-03-13 09:27:11 +0100
commit222dbb7bc9aa4424a78da93690f6262dd57347a3 (patch)
tree3c2c195a267b72c502084bfe87cfffe04ebde26f /lib
parent2976b3910251b18a039b663433a95e2cccaec5e9 (diff)
downloadnextcloud-server-222dbb7bc9aa4424a78da93690f6262dd57347a3.tar.gz
nextcloud-server-222dbb7bc9aa4424a78da93690f6262dd57347a3.zip
Made where varadic
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/DB/QueryBuilder/QueryBuilder.php6
-rw-r--r--lib/public/DB/QueryBuilder/IQueryBuilder.php2
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/private/DB/QueryBuilder/QueryBuilder.php b/lib/private/DB/QueryBuilder/QueryBuilder.php
index 4b3fd8449ce..a67e379617c 100644
--- a/lib/private/DB/QueryBuilder/QueryBuilder.php
+++ b/lib/private/DB/QueryBuilder/QueryBuilder.php
@@ -729,14 +729,14 @@ class QueryBuilder implements IQueryBuilder {
* ->where($or);
* </code>
*
- * @param mixed $predicates The restriction predicates.
+ * @param mixed ...$predicates The restriction predicates.
*
* @return \OCP\DB\QueryBuilder\IQueryBuilder This QueryBuilder instance.
*/
- public function where($predicates) {
+ public function where(...$predicates) {
call_user_func_array(
[$this->queryBuilder, 'where'],
- func_get_args()
+ $predicates
);
return $this;
diff --git a/lib/public/DB/QueryBuilder/IQueryBuilder.php b/lib/public/DB/QueryBuilder/IQueryBuilder.php
index 760496064fd..3d612b3a3ac 100644
--- a/lib/public/DB/QueryBuilder/IQueryBuilder.php
+++ b/lib/public/DB/QueryBuilder/IQueryBuilder.php
@@ -554,7 +554,7 @@ interface IQueryBuilder {
* @return \OCP\DB\QueryBuilder\IQueryBuilder This QueryBuilder instance.
* @since 8.2.0
*/
- public function where($predicates);
+ public function where(...$predicates);
/**
* Adds one or more restrictions to the query results, forming a logical