Cleanup initialization.
Make things less branchy. Thanks Job for the obvious suggestion I missed.