@@ -244,7 +244,8 @@ protected function _filterExt($action, $objName, $cmd=null)
244
244
}
245
245
246
246
$ cmd .= $ this ->_opts ['database ' ] . " $ action $ objName " ;
247
- $ output = $ ret = null ;
247
+ $ output = array ();
248
+ $ ret = null ;
248
249
exec ($ cmd , $ output , $ ret );
249
250
if ($ output ) {
250
251
echo "Error output from external filter: " .PHP_EOL .implode (PHP_EOL , $ output );
@@ -269,8 +270,14 @@ public function getReturnCode()
269
270
return self ::RETCODE_OK ;
270
271
}
271
272
273
+ /**
274
+ * Output information about backup data
275
+ *
276
+ * @return string
277
+ */
272
278
public function getInfo ()
273
279
{
280
+ return "backup " ;
274
281
}
275
282
276
283
protected function _connectMysql ()
@@ -356,7 +363,7 @@ public function cloneTo()
356
363
}
357
364
358
365
if (1 !==$ this ->_filterExt ($ subPath , $ fn )) {
359
- $ task = $ this ->_log ->subtask ()->log ("$ subPath: skip ' $ fn' because of external filter " );
366
+ $ this ->_log ->subtask ()->log ("$ subPath: skip ' $ fn' because of external filter " );
360
367
continue ;
361
368
}
362
369
@@ -582,7 +589,7 @@ function importDataFromFolderToRemoteServer($path, $truncate=true)
582
589
583
590
function importDataFromFolderToLocalServer ($ subPath , $ truncate =true )
584
591
{
585
- return $ this ->importDataFromFolder (true , $ path , $ truncate );
592
+ return $ this ->importDataFromFolder (true , $ subPath , $ truncate );
586
593
}
587
594
588
595
function importDataFromFolder ($ isLocalHost , $ subPath , $ truncate =true )
@@ -593,7 +600,7 @@ function importDataFromFolder($isLocalHost, $subPath, $truncate=true)
593
600
if ($ fn !=". " && $ fn !=".. " ) {
594
601
595
602
if (1 !==$ this ->_filterExt ($ subPath , $ fn )) {
596
- $ task = $ this ->_log ->subtask ()->log ("$ subPath: skip ' $ fn' because of external filter " );
603
+ $ this ->_log ->subtask ()->log ("$ subPath: skip ' $ fn' because of external filter " );
597
604
continue ;
598
605
}
599
606
@@ -627,6 +634,8 @@ function importDataFromFolder($isLocalHost, $subPath, $truncate=true)
627
634
}
628
635
closedir ($ handle );
629
636
}
637
+
638
+ return true ;
630
639
}
631
640
632
641
function execSqlFromFolderTogether ($ path )
@@ -664,7 +673,7 @@ function execSqlFromFolder($subPath, $tryRepeat=false)
664
673
$ fullFn = $ path .$ fn ;
665
674
666
675
if (1 !==$ this ->_filterExt ($ subPath , $ fn )) {
667
- $ task = $ this ->_log ->subtask ()->log ("skip ' $ fn' because of external filter " );
676
+ $ this ->_log ->subtask ()->log ("skip ' $ fn' because of external filter " );
668
677
continue ;
669
678
}
670
679
0 commit comments