[Zope-Checkins] CVS: Zope/lib/python/ZPublisher - HTTPResponse.py:1.69.4.2
Andy McKay
andy@agmweb.ca
Tue, 17 Dec 2002 13:36:26 -0500
Update of /cvs-repository/Zope/lib/python/ZPublisher
In directory cvs.zope.org:/tmp/cvs-serv31546
Modified Files:
Tag: Zope-2_6-branch
HTTPResponse.py
Log Message:
HTTPResponse.py patch for #342
=== Zope/lib/python/ZPublisher/HTTPResponse.py 1.69.4.1 => 1.69.4.2 ===
--- Zope/lib/python/ZPublisher/HTTPResponse.py:1.69.4.1 Wed Sep 25 12:06:25 2002
+++ Zope/lib/python/ZPublisher/HTTPResponse.py Tue Dec 17 13:36:26 2002
@@ -423,8 +423,11 @@
return body.encode('latin1','replace')
def setBase(self,base):
- 'Set the base URL for the returned document.'
- if not base.endswith('/'):
+ """Set the base URL for the returned document.
+ If base is None, or the document already has a base, do nothing."""
+ if base is None:
+ base = ''
+ elif not base.endswith('/'):
base = base+'/'
self.base = base