fix deploy and update func