Skip to content

Commit 0e4b66d

Browse files
authored
fixed
1 parent a43847b commit 0e4b66d

2 files changed

Lines changed: 10 additions & 8 deletions

File tree

ces_module_backup.php

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@ function recursive_copy($src, $dst) {
1111
mkdir($dst, 0777, true);
1212

1313
while(( $file = readdir($dir)) ) {
14-
if (( $file != '.' ) && ( $file != '..' )) {
14+
if (( substr($file, -1) != '_' ) && ( $file != '.' ) && ( $file != '..' )) {
1515
if ( is_dir($src . '/' . $file) ) {
1616
$this->recursive_copy($src .'/'. $file, $dst .'/'. $file);
1717
}
1818
else {
19+
// print_r($file);die;
1920
copy($src .'/'. $file, $dst .'/'. $file);
2021
}
2122
}
@@ -27,8 +28,10 @@ function recursive_copy($src, $dst) {
2728
$dir = substr($dst, 0, strrpos($dst, '/'));
2829
mkdir($dir, 0777, true);
2930
copy($src, $dst);
30-
}
31+
} else {
32+
die('<strong>Not found : </strong> ' . $src);
3133
// print_r($src);die;
34+
}
3235
}
3336
}
3437

@@ -50,11 +53,10 @@ function recursive_copy($src, $dst) {
5053
require_once $json['default_path'] . '/admin/config.php';
5154
require_once $json['default_path'] . '/config.php';
5255

53-
// foreach ($json['all_files'] as $key => $folder) {
54-
// $copy->recursive_copy($json['default_path'] . '/' . $folder, $fix_dst . $folder);
55-
// }
56+
foreach ($json['all_files'] as $key => $folder) {
57+
$copy->recursive_copy($json['default_path'] . '/' . $folder, $fix_dst . $folder);
58+
}
5659
foreach ($json['single_file'] as $key => $file) {
57-
// print_r($json['default_path'] . '/' . $file);
5860
$copy->recursive_copy($json['default_path'] . '/' . $file, $fix_dst . $file);
5961
}
6062
}

schema.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@
1515
"single_file": [
1616
"admin/controller/extension/module/ces_mobi_builder.php",
1717
"admin/language/en-gb/extension/module/ces_mobi_builder.php",
18-
"admin/model/ces_mobi_builder/extension/module/ces_mobi_builder.php",
18+
"admin/model/extension/module/ces_mobi_builder.php",
1919
"admin/view/javascript/ces/progressjs.min.js",
20-
"admin/view/template/ces_mobi_builder/extension/module/ces_mobi_builder.twig",
20+
"admin/view/template/extension/module/ces_mobi_builder.twig",
2121
"system/library/ces/cesAPI.php",
2222
"system/library/ces/cesMobiBuilder.php",
2323
"system/ces_mobi_builder.ocmod.xml"

0 commit comments

Comments
 (0)