Browse Source

fix:关闭未关闭的 admin 链接

liuyaqi 3 years ago
parent
commit
6f9a7d405f
1 changed files with 1 additions and 0 deletions
  1. 1 0
      service/srv/user.go

+ 1 - 0
service/srv/user.go

@@ -11,6 +11,7 @@ import (
 // GetUserList 返回用户列表
 func GetUserList(ctx context.Context, ids []int64, tenant string) ([]user_def.UserInfoList, error) {
 	userService := micro_srv.InitMicroSrvClient("User", "micro_srv.admin")
+	defer userService.Close()
 	rsp := &comm_def.CommonMsg{}
 	err := userService.Call(ctx, "GetUserInfoById", &comm_def.IdsReq{
 		Tenant: tenant,