code: func (s *Service) UpdateTarget(ctx context.Context, update *platform.ScraperTarget) (target *platform.ScraperTarget, err error) {
  	op := OpPrefix + platform.OpUpdateTarget
  	if !update.ID.Valid() {
  		return nil, &platform.Error{
  			Code: platform.EInvalid,
  			Op:   op,
  			Msg:  "id is invalid",
  		}
  	}
  	_, pe := s.loadScraperTarget(update.ID)
  	if pe != nil {
  		return nil, &platform.Error{
  			Op:  op,
  			Err: pe,
  		}
  	}
  	if err = s.PutTarget(ctx, update); err != nil {
  		return nil, &platform.Error{
  			Op:  op,
  			Err: pe,
  		}
  	}
  
  	return update, nil
  }
docs: // UpdateTarget updates a scraper target.