[Issue #174][Finished] fixed redundant == 0 check