changed logic again!