Changeset 939
- Timestamp:
- 01/25/06 10:26:13
- Files:
-
- trunk/cherrypy/__init__.py (modified) (2 diffs)
- trunk/cherrypy/_cphttptools.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/cherrypy/__init__.py
r928 r939 4 4 5 5 import datetime 6 import os.path7 6 import sys 8 7 import types … … 101 100 102 101 logfunc(msg, context, severity) 103 104 def url(u):105 return request.app_path + utrunk/cherrypy/_cphttptools.py
r926 r939 270 270 names = [name for name, candidate in objectTrail] 271 271 272 # Try to get app_path:273 current_objectpath = objectpath274 for i in xrange(len(objectTrail) - 1, -1, -1):275 name, candidate = objectTrail[i]276 if getattr(candidate, 'is_app_root', False):277 cherrypy.request.app_path = current_objectpath278 break279 current_objectpath = os.path.dirname(current_objectpath)280 281 272 # Try successive objects (reverse order) 282 273 mounted_app_roots = cherrypy.tree.mount_points.values()

