Beautify
Change code to check all variables (if) instead of (else-if)