added loadIcon method for easier maintainability and readability