Removing useless resources.