Commit 0d7358b6 authored by Vincent Pelletier's avatar Vincent Pelletier

Reuse existing "site" variable instea dof calling getPortalObject again.

Update comment.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@19375 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 819eca53
...@@ -4593,9 +4593,8 @@ Business Template is a set of definitions, such as skins, portal types and categ ...@@ -4593,9 +4593,8 @@ Business Template is a set of definitions, such as skins, portal types and categ
if update_translation: if update_translation:
site.ERP5Site_updateTranslationTable() site.ERP5Site_updateTranslationTable()
# It is better to clear cache because the installation of a template # Clear cache to avoid reusing cached values with replaced objects.
# adds many new things into the portal. site.portal_caches.clearAllCache()
self.getPortalObject().portal_caches.clearAllCache()
security.declareProtected(Permissions.ManagePortal, 'install') security.declareProtected(Permissions.ManagePortal, 'install')
def install(self, **kw): def install(self, **kw):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment