mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-10 07:34:06 -08:00
[imports] fix "Backup before importing?" checkbox on import page
We were always taking backups before import, no matter the status of this box. Turns out we were testing for the presence of the property defined by the checkbox, rather than the value of the property, and as such were always doing a backup. We're now checking the status, and it behaves as expected
This commit is contained in:
parent
4b01909806
commit
d3bcc48ae5
|
@ -127,7 +127,7 @@ class ImportController extends Controller
|
|||
$this->authorize('import');
|
||||
|
||||
// Run a backup immediately before processing
|
||||
if ($request->has('run-backup')) {
|
||||
if ($request->get('run-backup')) {
|
||||
\Log::debug('Backup manually requested via importer');
|
||||
Artisan::call('backup:run');
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue