Permalink
Browse files

fix a problem in finding objects for absolute links

  • Loading branch information...
1 parent d755e15 commit 40bb1c696560df046b9b5144ffc5dd3b58be5dd6 @davisagli davisagli committed Feb 24, 2012
Showing with 5 additions and 1 deletion.
  1. +4 −0 CHANGES.txt
  2. +1 −1 plone/app/linkintegrity/handlers.py
View
@@ -4,6 +4,10 @@ Changelog
1.4.5 - unreleased
------------------
+- Fix an error in handling absolute links to objects within the portal,
+ which prevented references from being created based on those links.
+ [davisagli]
+
- Stabilize the sort order of breach sources returned for the
confirmation view.
[davisagli]
@@ -23,7 +23,7 @@ def findObject(base, path):
if path.startswith('/'):
obj = getToolByName(base, 'portal_url').getPortalObject()
portal_path = '/'.join(obj.getPhysicalPath())
- components = path.lstrip(portal_path + '/').split('/')
+ components = path[len(portal_path) + 1:].split('/')
else:
obj = aq_parent(base) # relative urls start at the parent...
components = path.split('/')

0 comments on commit 40bb1c6

Please sign in to comment.