Can you extract this code into a function based on icc?

Right now we are doing almost the same changing iccs and labels, sure we can refactor in a method.