Swaps defer date times now too

Swaps defer date times now too
Fixed bug of not checking for a valid due or defer date
Refactored code