Merge branch 'devel' of dev.sourcefabric.org:airtime into devel
This commit is contained in:
commit
3dc96e3422
|
@ -1211,6 +1211,7 @@ EOT;
|
||||||
|
|
||||||
$insertList = array();
|
$insertList = array();
|
||||||
$totalTime = 0;
|
$totalTime = 0;
|
||||||
|
$totalItems = 0;
|
||||||
|
|
||||||
// this moves the pointer to the first element in the collection
|
// this moves the pointer to the first element in the collection
|
||||||
$files->getFirst();
|
$files->getFirst();
|
||||||
|
@ -1220,7 +1221,9 @@ EOT;
|
||||||
$length = Application_Common_DateHelper::calculateLengthInSeconds($iterator->current()->getDbLength());
|
$length = Application_Common_DateHelper::calculateLengthInSeconds($iterator->current()->getDbLength());
|
||||||
$insertList[$id] = $length;
|
$insertList[$id] = $length;
|
||||||
$totalTime += $length;
|
$totalTime += $length;
|
||||||
if ( !is_null($limit['items']) && $limit['items'] == count($insertList)) {
|
$totalItems++;
|
||||||
|
|
||||||
|
if ((!is_null($limit['items']) && $limit['items'] == count($insertList)) || $totalItems > 500) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue