Remove error caused by improper logic.