def profileListFunc(self): self.profileList.clear() if hue.profile_list(): for p in hue.profile_list(): self.profileList.addItem(QListWidgetItem(p))