Updated js and randGen