add some
Some checks failed
CI/CD / Vet, test, build (push) Has been cancelled
CI/CD / Docker image (push) Has been cancelled
CI/CD / Deploy binary to server (push) Has been cancelled

This commit is contained in:
2026-09-19 04:47:43 +05:00
parent 6c7c402390
commit 599c12ef87
9 changed files with 68 additions and 25 deletions

View File

@@ -171,7 +171,7 @@ func (h *handler) handleError(c *gin.Context, err error, action string) bool {
switch {
case errors.Is(err, pgx.ErrNoRows):
c.JSON(http.StatusNotFound, appresult.ErrNotFound)
case errors.Is(err, ErrAlreadyPaid), errors.Is(err, ErrAmountNotSet), errors.Is(err, ErrAmountExceedsMax):
case errors.Is(err, ErrAlreadyPaid), errors.Is(err, ErrAmountNotSet), errors.Is(err, ErrAmountExceedsMax), errors.Is(err, ErrPaymentWindowClosed):
c.JSON(http.StatusBadRequest, appresult.ErrNotAcceptable)
default:
h.logger.Errorf("%s visa master payment order failed: %v", action, err)