Skip to content

Commit

Permalink
Fix #32 Dateien im Backup-Order werden nach Deinstallation nicht gelö…
Browse files Browse the repository at this point in the history
…scht
  • Loading branch information
aeberhard committed Jun 6, 2023
1 parent 1b9cda6 commit 31eb044
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions uninstall.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,24 @@

$addon = rex_addon::get('demo_fullpage');

// Delete Backup-Files
$setupconfig = (array) $addon->getProperty('setup');
$backupPath = rex_addon::get('backup')->getDataPath();

if (isset($setupconfig['dbimport']) && is_array($setupconfig['dbimport']) &&count($setupconfig['dbimport']) > 0) {
foreach ($setupconfig['dbimport'] as $import) {
rex_file::delete($backupPath . $import);
}
}

if (isset($setupconfig['fileimport']) && is_array($setupconfig['fileimport']) && count($setupconfig['fileimport']) > 0) {
foreach ($setupconfig['fileimport'] as $import) {
rex_file::delete($backupPath.$import);
}
}

// rex_addon::get('backup')->getDataPath()

// update config
// remove additional config from base config
$config = array_diff_recursive(
Expand Down

0 comments on commit 31eb044

Please sign in to comment.