Clear caches when theme is changed

merge-requests/8/head
Bob Mottram 2020-12-09 15:45:54 +00:00
parent 14d7985353
commit 222375f2ab
1 changed files with 4 additions and 0 deletions

View File

@ -3826,6 +3826,8 @@ class PubServer(BaseHTTPRequestHandler):
self.server.themeName = fields['themeDropdown']
setTheme(baseDir, self.server.themeName, domain,
allowLocalNetworkAccess)
self.server.iconsCache = {}
self.server.fontsCache = {}
self.server.showPublishAsIcon = \
getConfigParam(self.server.baseDir,
'showPublishAsIcon')
@ -4199,6 +4201,8 @@ class PubServer(BaseHTTPRequestHandler):
self.server.themeName = currTheme
setTheme(baseDir, currTheme, domain,
self.server.allowLocalNetworkAccess)
self.server.iconsCache = {}
self.server.fontsCache = {}
self.server.showPublishAsIcon = \
getConfigParam(self.server.baseDir,
'showPublishAsIcon')