Corrected expiry calculation