Added exception handling to icon processing