🔥 Fait le ménage des deals supprimés

This commit is contained in:
Shikiryu 2017-11-08 22:17:51 +01:00
parent 2bb5bb7b5b
commit 162987131b

View File

@ -82,6 +82,8 @@ if ($actions->connect()) {
foreach ($deals_to_backup as $deal_to_backup) {
if (!file_exists(BACKUP_DEALS_DIR.'/'.$deal_to_backup->getId())) {
rename(EXISTING_DEALS_DIR . '/' . $deal_to_backup->getId(), BACKUP_DEALS_DIR . '/' . $deal_to_backup->getId());
} else {
delete_folder(EXISTING_DEALS_DIR . '/' . $deal_to_backup->getId());
}
}