diff --git a/internal/rpc/auth/auth.go b/internal/rpc/auth/auth.go index aec22cfe52..7d33ef9282 100644 --- a/internal/rpc/auth/auth.go +++ b/internal/rpc/auth/auth.go @@ -78,7 +78,7 @@ func (s *authServer) UserToken(ctx context.Context, req *pbauth.UserTokenReq) (* return nil, errs.ErrNoPermission.WrapMsg("secret invalid") } - if datautil.Contain(req.UserID, s.config.Share.IMAdminUserID...) { + if !datautil.Contain(req.UserID, s.config.Share.IMAdminUserID...) { return nil, errs.ErrArgs.WrapMsg("userID is error.", "userID", req.UserID, "adminUserID", s.config.Share.IMAdminUserID) }