now edit works with id parameter and update closure