From 2cd783dfa6dcb70f39799419c95d534a0f137acd Mon Sep 17 00:00:00 2001 From: Matias Griese Date: Thu, 18 Feb 2021 15:38:49 +0200 Subject: [PATCH] Fixed Admin creating empty `user/config/info.yaml` file (the file can be safely removed, it is not in use) --- CHANGELOG.md | 1 + admin.php | 3 +++ 2 files changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6dc8361b..4ccebc33 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ 1. [](#bugfix) * Fixed fatal error in admin if POST request has `data` in it [#2074](https://github.com/getgrav/grav-plugin-admin/issues/2074) + * Fixed Admin creating empty `user/config/info.yaml` file (the file can be safely removed, it is not in use) # v1.10.4 ## 02/17/2021 diff --git a/admin.php b/admin.php index bafa24b7..e1069f99 100644 --- a/admin.php +++ b/admin.php @@ -1067,6 +1067,9 @@ class AdminPlugin extends Plugin // Double check we have system.yaml, site.yaml etc $config_path = $this->grav['locator']->findResource('user://config'); foreach ($this->admin::configurations() as $config_file) { + if ($config_file === 'info') { + continue; + } $config_file = "{$config_path}/{$config_file}.yaml"; if (!file_exists($config_file)) { touch($config_file);