Rearrange code in js