Added paste deletion and fixed ID finding