PIM-2961: Clean loop to get association