|
@@ -25,7 +25,11 @@ class CronAction extends Action {
|
|
|
}else{
|
|
|
$zip = $this->zip($path_parts['filename'], $path_parts['dirname']);
|
|
|
}
|
|
|
- if ($zip && filesize($zip) > 0) {//压缩完成
|
|
|
+ if ($zip) {//压缩完成
|
|
|
+ if(filesize($zip) <= 0){
|
|
|
+ @unlink($zip);
|
|
|
+ continue;
|
|
|
+ }
|
|
|
//echo '压缩用时:'.(time()-$start).PHP_EOL;
|
|
|
$tagetDat = $targetDir . '/' . $path_parts['filename'] . '.zip';
|
|
|
//echo $tagetDat . PHP_EOL;
|