# HG changeset patch # User Lennard de Rijk # Date 1244145717 -7200 # Node ID a518ea56f6b535551665fc8d99775538f7b81bc7 # Parent 71780864a5ed3458dab2a664c4331e7d92ba0acf Fixed an issue where some access checks would fail due to missing arguments. This happens when an org document is being checked for write access when trying to show the edit link on the document's show page. diff -r 71780864a5ed -r a518ea56f6b5 app/soc/views/models/document.py --- a/app/soc/views/models/document.py Thu Jun 04 21:58:05 2009 +0200 +++ b/app/soc/views/models/document.py Thu Jun 04 22:01:57 2009 +0200 @@ -135,13 +135,17 @@ allowed_to_edit = False try: # use the IsDocumentWritable check because we have no django args - rights.checkIsDocumentWritable({'key_name': entity.key().name()}, + rights.checkIsDocumentWritable({'key_name': entity.key().name(), + 'prefix': entity.prefix, + 'scope_path': entity.scope_path, + 'link_id': entity.link_id}, 'key_name') allowed_to_edit = True except: pass if allowed_to_edit: + # add the document edit redirect to the context context['edit_redirect'] = redirects.getEditRedirect( entity, {'url_name': 'document'})