Merge pull request #5134 from devansh-webkul/multiple-custom-script-issue

Fixed error in Admin -> Configuration after added custom scripts #5113
This commit is contained in:
Glenn Hermans 2021-09-06 20:54:22 +02:00 committed by GitHub
commit 9a0172d133
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -91,7 +91,9 @@ class CoreConfigRepository extends Repository
]);
} else {
foreach ($coreConfigValue as $coreConfig) {
Storage::delete($coreConfig['value']);
if (request()->hasFile($fieldName)) {
Storage::delete($coreConfig['value']);
}
if (isset($value['delete'])) {
$this->model->destroy($coreConfig['id']);