remove anti pattern each with return