Fixed mux divide by zero error