I found a newer simpler version:
=IFERROR(TEXTJOIN(", ",TRUE,UNIQUE(B1:K1,TRUE,FALSE)),"")
And also one that works if the cells you want to combine are already lists:
=IFERROR(TEXTJOIN(", ", TRUE, UNIQUE(TEXTSPLIT(TEXTJOIN(", ",TRUE,B1:K1),", "),TRUE,FALSE)),"")