update scripts code