Use & instead of your large and error prone if statements

hi, if you use ´|=´ you can use ´&´, too :-)