removing unwanted code