'use strict';module.exports=functionunion(init){if(!Array.isArray(init)){thrownewTypeError('arr-union expects the first argument to be an array.');}varlen=arguments.length;vari=0;while(++i<len){vararg=arguments[i];if(!arg)continue;if(!Array.isArray(arg)){arg=[arg];}for(varj=0;j<arg.length;j++){varele=arg[j];if(init.indexOf(ele)>=0){continue;}init.push(ele);}}returninit;};