diff --git a/app/Libraries/HTMLUtils.php b/app/Libraries/HTMLUtils.php
index ad8ea6c8cb53..1b42f1bbe7b7 100644
--- a/app/Libraries/HTMLUtils.php
+++ b/app/Libraries/HTMLUtils.php
@@ -22,6 +22,7 @@ class HTMLUtils
$config->set('CSS.AllowImportant', true);
$config->set('CSS.AllowTricky', true);
$config->set('CSS.Trusted', true);
+ $config->set('Cache.SerializerPath', base_path('storage/framework/cache'));
// Create a new purifier instance
$purifier = new HTMLPurifier($config);
@@ -42,6 +43,8 @@ class HTMLUtils
$html = html_entity_decode($html);
$config = HTMLPurifier_Config::createDefault();
+ $config->set('Cache.SerializerPath', base_path('storage/framework/cache'));
+
$purifier = new HTMLPurifier($config);
return $purifier->purify($html);