Removing unnecessary attributes