diff --git a/upload/api/db/dbbak.php b/upload/api/db/dbbak.php index 6885d413ad560e77a2109fe097b7843adbae1c20..47a0aac1b029fa59bb857308e2da413f59c0d52e 100644 --- a/upload/api/db/dbbak.php +++ b/upload/api/db/dbbak.php @@ -562,7 +562,7 @@ if($get['method'] == 'export') { $directory = dir(BACKUP_DIR); while($entry = $directory->read()) { $filename = BACKUP_DIR.$entry; - if(is_dir($filename) && preg_match('/^backup_(\d+)_\w+$/', $filename, $match)) { + if(is_dir($filename) && preg_match('/^backup_(\d+)_\w+$/', $entry, $match)) { $str .= "\t\n"; $str .= "\t\t$filename\n"; $str .= "\t\t$match[1]\n"; diff --git a/upload/uc_server/api/dbbak.php b/upload/uc_server/api/dbbak.php index 42b2aa53e9776e5a77c05b119fade37de09259a8..e5b4e46b300da4e4eaf61478d07ccac4793d4230 100644 --- a/upload/uc_server/api/dbbak.php +++ b/upload/uc_server/api/dbbak.php @@ -558,7 +558,7 @@ if($get['method'] == 'export') { $directory = dir(BACKUP_DIR); while($entry = $directory->read()) { $filename = BACKUP_DIR.$entry; - if(is_dir($filename) && preg_match('/^backup_(\d+)_\w+$/', $filename, $match)) { + if(is_dir($filename) && preg_match('/^backup_(\d+)_\w+$/', $entry, $match)) { $str .= "\t\n"; $str .= "\t\t$filename\n"; $str .= "\t\t$match[1]\n";