Skip to content

Commit f7ffc56

Browse files
committed
- fixed compatibility with PHP 5.5.9
1 parent 904dd0b commit f7ffc56

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Model.php

+3-1
Original file line numberDiff line numberDiff line change
@@ -768,8 +768,10 @@ public function update($attributes, $condition=NULL, $runValidation=true)
768768
* [['title'=>'A2', 'modified'=>'1'], ['id'=>2]],
769769
* ];);
770770
*/
771-
public function batchUpdate(Array $dataSet, $withAll=false, $maxLength=4*1024*1024, $runValidation=true)
771+
public function batchUpdate(Array $dataSet, $withAll=false, $maxLength=null, $runValidation=true)
772772
{
773+
$maxLength = $maxLength ?: 4 * 1024 * 1024;
774+
773775
$count = 0;
774776
$sqlBatch = '';
775777

0 commit comments

Comments
 (0)