delete uneccessery resources