Added better remove logic.