Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
andrelopez committed Jun 1, 2018
2 parents 568c99c + 25c9892 commit 15e06e9
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Enupal Backup Changelog

## 1.1.3 - 2018.06.01
### Fixed
- Fixed scenario where Config Files download button should not be displayed

## 1.1.2 - 2018.05.31
### Added
- Added Config Files as option to backup
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "enupal/backup",
"description": "Fully integrated Backup solution for Craft CMS",
"type": "craft-plugin",
"version": "1.1.2",
"version": "1.1.3",
"keywords": [
"craft",
"cms",
Expand Down
14 changes: 14 additions & 0 deletions src/controllers/BackupsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,20 @@ public function actionViewBackup(int $backupId)

$backup->assetFileName = $assetFileName;

$configFiles = [];
$backup->getConfigFiles($configFiles);

$configFileName = null;
foreach ($configFiles as $configFile) {
if (is_file($configFile)) {
// If we have a least one file we should allow download it.
$configFileName = "config";
break;
}
}

$backup->configFileName = $configFileName;

$variables = [];

$variables['backup'] = $backup;
Expand Down

0 comments on commit 15e06e9

Please sign in to comment.