summaryrefslogtreecommitdiffstats
path: root/lib/connector/sabre/directory.php
diff options
context:
space:
mode:
authorThomas Mueller <thomas.mueller@tmit.eu>2012-11-06 13:55:30 +0100
committerThomas Mueller <thomas.mueller@tmit.eu>2012-11-06 13:55:30 +0100
commit07ffa0de39f410b1c6d70608b7cdeb39275ae670 (patch)
treed470b47f9eb344442382df3dea79be1eb399f8fb /lib/connector/sabre/directory.php
parent415ec58422415f67c0475d9bc9aef92ab7451770 (diff)
downloadnextcloud-server-07ffa0de39f410b1c6d70608b7cdeb39275ae670.tar.gz
nextcloud-server-07ffa0de39f410b1c6d70608b7cdeb39275ae670.zip
adding comments to explain what's going on here
Diffstat (limited to 'lib/connector/sabre/directory.php')
-rw-r--r--lib/connector/sabre/directory.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/connector/sabre/directory.php b/lib/connector/sabre/directory.php
index 388936bc96e..6076aed6fcd 100644
--- a/lib/connector/sabre/directory.php
+++ b/lib/connector/sabre/directory.php
@@ -123,6 +123,10 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node implements Sa
}
$properties = array_fill_keys($paths, array());
if(count($paths)>0) {
+ //
+ // the number of arguments within IN conditions are limited in most databases
+ // we chunk $paths into arrays of 200 items each to meet this criteria
+ //
$chunks = array_chunk($paths, 200, false);
foreach ($chunks as $pack) {
$placeholders = join(',', array_fill(0, count($pack), '?'));