ensure required javascript array is uniq'd