Commit 5c35a807 authored by Kevin Deldycke's avatar Kevin Deldycke

Don't let the script crash if no default document found

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@8703 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent fbba5072
No related merge requests found
......@@ -68,7 +68,10 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>return context.WebSite_getDefaultDocumentValue().WebSite_getUrl()\n
<value> <string>default_document = context.WebSite_getDefaultDocumentValue()\n
if default_document:\n
return default_document.WebSite_getUrl()\n
return None\n
</string> </value>
</item>
<item>
......@@ -113,6 +116,8 @@
<tuple>
<string>_getattr_</string>
<string>context</string>
<string>default_document</string>
<string>None</string>
</tuple>
</value>
</item>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment