@@ -117,7 +117,7 @@ public function __construct(ILogger $logger,
117117		$ this serverRoot    = $ serverRoot
118118		$ this cacheFactory  = $ cacheFactory
119119		$ this depsCache     = $ cacheFactorycreateDistributed ('SCSS-deps- '  . md5 ($ this urlGenerator ->getBaseUrl ()));
120- 		$ this isCachedCache  = $ cacheFactorycreateLocal ('SCSS-cached- '  . md5 ($ this urlGenerator ->getBaseUrl ()));
120+ 		$ this isCachedCache  = $ cacheFactorycreateDistributed ('SCSS-cached- '  . md5 ($ this urlGenerator ->getBaseUrl ()));
121121		$ lockingCache$ cacheFactorycreateDistributed ('SCSS-locks- '  . md5 ($ this urlGenerator ->getBaseUrl ()));
122122		if  (!($ lockingCacheinstanceof  IMemcache)) {
123123			$ lockingCachenew  NullCache ();
@@ -269,8 +269,8 @@ private function isCached(string $fileNameCSS, string $app) {
269269	private  function  variablesChanged (): bool  {
270270		$ injectedVariables$ this getInjectedVariables ();
271271		if  ($ this config ->getAppValue ('core ' , 'theming.variables ' ) !== md5 ($ injectedVariables
272- 			$ this resetCache ();
273272			$ this config ->setAppValue ('core ' , 'theming.variables ' , md5 ($ injectedVariables
273+ 			$ this resetCache ();
274274			return  true ;
275275		}
276276		return  false ;
@@ -364,6 +364,9 @@ private function cache(string $path, string $fileNameCSS, string $fileNameSCSS,
364364	 * We need to regenerate all files when variables change 
365365	 */ 
366366	public  function  resetCache () {
367+ 		if  (!$ this lockingCache ->add ('resetCache ' , 'locked! ' , 120 )) {
368+ 			return ;
369+ 		}
367370		$ this injectedVariables  = null ;
368371
369372		// do not clear locks 
@@ -381,6 +384,7 @@ public function resetCache() {
381384			}
382385		}
383386		$ this logger ->debug ('SCSSCacher: css cache cleared! ' );
387+ 		$ this lockingCache ->remove ('resetCache ' );
384388	}
385389
386390	/** 
0 commit comments