update deploy function