浏览代码

v8-2811 add a clear-cache after the creation of a new organization

Olivier Massot 3 年之前
父节点
当前提交
e083052372
共有 1 个文件被更改,包括 5 次插入0 次删除
  1. 5 0
      ot_admin/Classes/Controller/SiteController.php

+ 5 - 0
ot_admin/Classes/Controller/SiteController.php

@@ -603,6 +603,11 @@ class SiteController extends ActionController
                 throw new \RuntimeException('Something went wrong while committing the result');
             }
 
+            // Clear the whole cache, to avoid errors with the configuration files cache
+            //      >> this could probably be improved by targeting the caches to clean
+            //         more precisely, but that'll do for the moment
+            OtCacheManager::clearCache(false);
+
         } catch(\Throwable $e) {
             // rollback
             $this->connectionPool->getConnectionByName('Default')->rollback();