--- a/server/session.py Fri Jul 24 09:31:43 2009 +0200
+++ b/server/session.py Fri Jul 24 10:36:57 2009 +0200
@@ -194,7 +194,14 @@
raise KeyError(eid)
def base_url(self):
- return self.repo.config['base-url'] or u''
+ url = self.repo.config['base-url']
+ if not url:
+ try:
+ url = self.repo.config.default_base_url()
+ except AttributeError: # default_base_url() might not be available
+ self.warning('missing base-url definition in server config')
+ url = u''
+ return url
def from_controller(self):
"""return the id (string) of the controller issuing the request (no