removing unwanted components