Given the way you are handling the defaults, I don't believe you want this if condition. I would delete lines 98, 107-108 (and fix the indentation).