generated from VLADIMIR/template
fix add team
This commit is contained in:
@@ -545,7 +545,7 @@ func (s *server) AddTeam(ctx context.Context, req *proto.AddTeamReq) (*proto.Add
|
||||
return nil, status.Errorf(codes.PermissionDenied, "permission denied")
|
||||
}
|
||||
|
||||
err := s.gameService.AddTeam(
|
||||
team, err := s.gameService.AddTeam(
|
||||
ctx,
|
||||
claims.UserID,
|
||||
int(req.GameId),
|
||||
@@ -557,7 +557,10 @@ func (s *server) AddTeam(ctx context.Context, req *proto.AddTeamReq) (*proto.Add
|
||||
}, nil
|
||||
}
|
||||
|
||||
return &proto.AddTeamRsp{}, nil
|
||||
return &proto.AddTeamRsp{
|
||||
Id: int32(team.ID),
|
||||
Password: team.Password,
|
||||
}, nil
|
||||
}
|
||||
|
||||
func (s *server) UpdateTeam(ctx context.Context, req *proto.UpdateTeamReq) (*proto.UpdateTeamRsp, error) {
|
||||
|
||||
Reference in New Issue
Block a user