Trying to fix https://bugs.launchpad.net/zope2/+bug/1386795

Seems to work - at least zope starts for us.

I'm appending more fixes as I discover them.
Prefer the `getattr(foo, 'bar', 'baz')` to the more awkward `if hasattr()` form.