update collection js