MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / applyCoreAuthAddOrUpdate

Method applyCoreAuthAddOrUpdate

sdk/cliproxy/service.go:672–679  ·  view source on GitHub ↗
(ctx context.Context, auth *coreauth.Auth)

Source from the content-addressed store, hash-verified

670}
671
672func (s *Service) applyCoreAuthAddOrUpdate(ctx context.Context, auth *coreauth.Auth) {
673 auth = s.prepareCoreAuthForModelRegistration(ctx, auth)
674 if auth == nil {
675 return
676 }
677 s.completeModelRegistrationForAuth(ctx, auth)
678 s.syncPluginRuntime(ctx)
679}
680
681func (s *Service) prepareCoreAuthForModelRegistration(ctx context.Context, auth *coreauth.Auth) *coreauth.Auth {
682 if s == nil || s.coreManager == nil || auth == nil || auth.ID == "" {