add checkDateAgainstOtherDate function