Commit d2f6842f authored by Antoine Catton's avatar Antoine Catton

Revert "Use default parameter of get method instead of “à la shell” expressions."

This reverts commit 99d1c52c.

My mistake. We used :
  dict.get("key") or "default"
instead of :
  dict.get("key", "default")

because some time dict["key"] is None.
parent 99d1c52c
......@@ -59,11 +59,11 @@ portal = person.getPortalObject()\n
kwargs = state_change.kwargs\n
software_release_url_string = state_change.kwargs[\'software_release\']\n
software_title = kwargs["software_title"]\n
software_type = kwargs.get("software_type", "RootSoftwareInstance")\n
software_type = kwargs.get("software_type") or "RootSoftwareInstance"\n
instance_xml = kwargs["instance_xml"]\n
sla_xml = kwargs.get("sla_xml", "")\n
sla_xml = kwargs.get("sla_xml") or ""\n
is_slave = kwargs.get("shared", False)\n
state = kwargs.get(\'state\', \'started\')\n
state = kwargs.get(\'state\') or \'started\'\n
\n
sale_order_portal_type = "Sale Order"\n
sale_order_line_portal_type = "Sale Order Line"\n
......
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