One more thing.

I just realized the second else statement is actually necessary so I added it back.