implemented removeRow logic