Commit bf93863b authored by Georgios Dagkakis's avatar Georgios Dagkakis

remove FilesystemDocumentTemplateItem._importFile

parent 23ac4c9c
......@@ -3831,13 +3831,6 @@ class FilesystemDocumentTemplateItem(BaseTemplateItem):
key = extra_prefix + key
bta.addObject(obj, name=key, ext='.py')
def _importFile(self, file_name, file):
if not file_name.endswith('.py'):
LOG('Business Template', 0, 'Skipping file "%s"' % (file_name, ))
return
text = file.read()
self._objects[file_name[:-3]] = text
class FilesystemToZodbTemplateItem(FilesystemDocumentTemplateItem,
ObjectTemplateItem):
"""
......@@ -3914,17 +3907,6 @@ class FilesystemToZodbTemplateItem(FilesystemDocumentTemplateItem,
build = _filesystemCompatibilityWrapper('build', '_archive')
preinstall = _filesystemCompatibilityWrapper('preinstall', '_objects')
def _importFile(self, file_name, *args, **kw):
"""
Import file by calling the appropriate base class according to the file
name extensions
"""
if file_name.endswith('.xml'):
return ObjectTemplateItem._importFile(self, file_name, *args, **kw)
else:
return FilesystemDocumentTemplateItem._importFile(self, file_name,
*args, **kw)
def afterUninstall(self, already_migrated=False):
"""
Hook called after uninstall
......
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