generated from VLADIMIR/template
fix
This commit is contained in:
@@ -53,7 +53,7 @@ func (s *server) AcceptTicket(ctx context.Context, req *proto.AcceptTicketReq) (
|
||||
}
|
||||
page, err := s.ticketService.Accept(ctx, req.Token, claims.UserID)
|
||||
if err != nil {
|
||||
return &proto.AcceptTicketRsp{Error: err.Error()}, nil
|
||||
return nil, ticketErrorStatus(err, "не удалось принять билет")
|
||||
}
|
||||
result := &proto.TicketPage{ID: int32(page.ID), GameName: page.GameName, StartAt: timestamppb.New(page.StartAt), Status: page.Status, GameStatus: page.GameStatus}
|
||||
if page.Location != nil {
|
||||
@@ -82,7 +82,7 @@ func (s *server) IssueGameTickets(ctx context.Context, req *proto.IssueGameTicke
|
||||
|
||||
tickets, err := s.ticketService.Issue(ctx, int(req.GameID), int(req.Count))
|
||||
if err != nil {
|
||||
return &proto.IssueGameTicketsRsp{Error: err.Error()}, nil
|
||||
return nil, ticketErrorStatus(err, "не удалось выпустить билеты")
|
||||
}
|
||||
|
||||
result := make([]*proto.Ticket, 0, len(tickets))
|
||||
|
||||
Reference in New Issue
Block a user