index condition

added a new else clause