Updated if to case