Javascript Copy And Sort Array Of Strings