Error handling for session expiration