put an expiration on previous session usage
fix datetime compare