shoudl use else instead of next