[CMF-checkins] CVS: Products/CMFCore - DirectoryView.py:1.47.2.2
Yvo Schubbe
y.2004_ at wcm-solutions.de
Mon Aug 30 10:05:06 EDT 2004
Update of /cvs-repository/Products/CMFCore
In directory cvs.zope.org:/tmp/cvs-serv27053/CMFCore
Modified Files:
Tag: CMF-1_5-branch
DirectoryView.py
Log Message:
- improved createDirectoryView() backwards compatibility
=== Products/CMFCore/DirectoryView.py 1.47.2.1 => 1.47.2.2 ===
--- Products/CMFCore/DirectoryView.py:1.47.2.1 Tue Aug 17 04:09:29 2004
+++ Products/CMFCore/DirectoryView.py Mon Aug 30 10:05:06 2004
@@ -484,7 +484,16 @@
"""
info = _dirreg.getDirectoryInfo(minimal_fp)
if info is None:
- raise ValueError('Not a registered directory: %s' % minimal_fp)
+ fixed_minimal_fp = minimal_fp.replace('\\','/')
+ info = _dirreg.getDirectoryInfo(fixed_minimal_fp)
+ if info is None:
+ raise ValueError('Not a registered directory: %s' % minimal_fp)
+ else:
+ warn('createDirectoryView() expects a slash-separated path '
+ 'relative to the Products path. \'%s\' will no longer work '
+ 'in CMF 1.6.' % minimal_fp,
+ DeprecationWarning)
+ minimal_fp = fixed_minimal_fp
if not id:
id = minimal_fp.split('/')[-1]
else:
More information about the CMF-checkins
mailing list