mirror of
https://github.com/getAlby/lndhub.go.git
synced 2026-02-23 13:54:25 +01:00
Merge pull request #429 from getAlby/task-logging
chore: add missing logs
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/getsentry/sentry-go"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// AddInvoiceController : Add invoice controller struct
|
||||
@@ -50,6 +51,14 @@ func AddInvoice(c echo.Context, svc *service.LndhubService, userID int64) error
|
||||
|
||||
amount, err := svc.ParseInt(body.Amount)
|
||||
if err != nil || amount < 0 {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"error": err,
|
||||
"message": "invalid amount",
|
||||
"lndhub_user_id": userID,
|
||||
"amount": amount,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
|
||||
@@ -63,7 +72,14 @@ func AddInvoice(c echo.Context, svc *service.LndhubService, userID int64) error
|
||||
if svc.Config.MaxAccountBalance > 0 {
|
||||
currentBalance, err := svc.CurrentUserBalance(c.Request().Context(), userID)
|
||||
if err != nil {
|
||||
return c.JSON(http.StatusBadRequest, responses.GeneralServerError)
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "error fetching balance",
|
||||
"lndhub_user_id": userID,
|
||||
"error": err,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
if currentBalance+amount > svc.Config.MaxAccountBalance {
|
||||
c.Logger().Errorf("Max account balance exceeded for user_id:%v (balance:%v + amount:%v)", userID, currentBalance, amount)
|
||||
|
||||
@@ -6,6 +6,7 @@ import (
|
||||
"github.com/getAlby/lndhub.go/lib/responses"
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// AuthController : AuthController struct
|
||||
@@ -49,6 +50,12 @@ func (controller *AuthController) Auth(c echo.Context) error {
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
if err := c.Validate(&body); err != nil {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"error": err,
|
||||
"message": "invalid request body",
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
|
||||
@@ -56,7 +63,13 @@ func (controller *AuthController) Auth(c echo.Context) error {
|
||||
// To support Swagger we also look in the Form data
|
||||
params, err := c.FormParams()
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "invalid form parameters",
|
||||
"error": err,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
login := params.Get("login")
|
||||
password := params.Get("password")
|
||||
@@ -69,8 +82,21 @@ func (controller *AuthController) Auth(c echo.Context) error {
|
||||
accessToken, refreshToken, err := controller.svc.GenerateToken(c.Request().Context(), body.Login, body.Password, body.RefreshToken)
|
||||
if err != nil {
|
||||
if err.Error() == responses.AccountDeactivatedError.Message {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "account deactivated",
|
||||
"user_login": body.Login,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusUnauthorized, responses.AccountDeactivatedError)
|
||||
}
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "authentication error",
|
||||
"user_login": body.Login,
|
||||
"error": err,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusUnauthorized, responses.BadAuthError)
|
||||
}
|
||||
|
||||
|
||||
@@ -3,8 +3,10 @@ package controllers
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"github.com/getAlby/lndhub.go/lib/responses"
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// BalanceController : BalanceController struct
|
||||
@@ -26,7 +28,14 @@ func (controller *BalanceController) Balance(c echo.Context) error {
|
||||
userId := c.Get("UserID").(int64)
|
||||
balance, err := controller.svc.CurrentUserBalance(c.Request().Context(), userId)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to retrieve user balance",
|
||||
"lndhub_user_id": userId,
|
||||
"error": err,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
return c.JSON(http.StatusOK, &BalanceResponse{
|
||||
BTC: struct{ AvailableBalance int64 }{
|
||||
|
||||
@@ -3,11 +3,12 @@ package controllers
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"github.com/getAlby/lndhub.go/lib/responses"
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/labstack/echo/v4"
|
||||
)
|
||||
|
||||
//Copy over struct for swagger purposes
|
||||
// Copy over struct for swagger purposes
|
||||
type GetInfoResponse struct {
|
||||
// The version of the LND software that the node is running.
|
||||
Version string `protobuf:"bytes,14,opt,name=version,proto3" json:"version,omitempty"`
|
||||
@@ -77,7 +78,8 @@ func (controller *GetInfoController) GetInfo(c echo.Context) error {
|
||||
|
||||
info, err := controller.svc.GetInfo(c.Request().Context())
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorf("failed to retrieve info: %v", err)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
if controller.svc.Config.CustomName != "" {
|
||||
info.Alias = controller.svc.Config.CustomName
|
||||
|
||||
@@ -5,8 +5,10 @@ import (
|
||||
|
||||
"github.com/getAlby/lndhub.go/common"
|
||||
"github.com/getAlby/lndhub.go/lib"
|
||||
"github.com/getAlby/lndhub.go/lib/responses"
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// GetTXSController : GetTXSController struct
|
||||
@@ -51,7 +53,14 @@ func (controller *GetTXSController) GetTXS(c echo.Context) error {
|
||||
|
||||
invoices, err := controller.svc.InvoicesFor(c.Request().Context(), userId, common.InvoiceTypeOutgoing)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to get transactions",
|
||||
"error": err,
|
||||
"lndhub_user_id": userId,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
|
||||
response := make([]OutgoingInvoice, len(invoices))
|
||||
@@ -78,7 +87,14 @@ func (controller *GetTXSController) GetUserInvoices(c echo.Context) error {
|
||||
|
||||
invoices, err := controller.svc.InvoicesFor(c.Request().Context(), userId, common.InvoiceTypeIncoming)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to get invoices",
|
||||
"error": err,
|
||||
"lndhub_user_id": userId,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
|
||||
response := make([]IncomingInvoice, len(invoices))
|
||||
|
||||
@@ -9,6 +9,7 @@ import (
|
||||
"net/url"
|
||||
"strings"
|
||||
|
||||
"github.com/getAlby/lndhub.go/lib/responses"
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/lightningnetwork/lnd/lnrpc"
|
||||
@@ -66,7 +67,8 @@ func (controller *HomeController) QR(c echo.Context) error {
|
||||
url := fmt.Sprintf("bluewallet:setlndhuburl?url=%s", encoded)
|
||||
png, err := qrcode.Encode(url, qrcode.Medium, 256)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorf("Error encoding QR: %v", err)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
return c.Blob(http.StatusOK, "image/png", png)
|
||||
}
|
||||
@@ -74,16 +76,19 @@ func (controller *HomeController) QR(c echo.Context) error {
|
||||
func (controller *HomeController) Home(c echo.Context) error {
|
||||
info, err := controller.svc.GetInfo(c.Request().Context())
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorf("Failed to retrieve info: %v", err)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
channels, err := controller.svc.LndClient.ListChannels(c.Request().Context(), &lnrpc.ListChannelsRequest{})
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorf("Failed to list channels: %v", err)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
|
||||
tmpl, err := template.New("index").Parse(controller.html)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorf("Failed to parse template: %v", err)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
// See original code: https://github.com/BlueWallet/LndHub/blob/master/controllers/website.js#L32
|
||||
maxChanCapacity := -1
|
||||
@@ -117,7 +122,8 @@ func (controller *HomeController) Home(c echo.Context) error {
|
||||
var buf bytes.Buffer
|
||||
err = tmpl.Execute(&buf, content)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorf("Failed to parse template: %v", err)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
c.Response().Header().Set(echo.HeaderCacheControl, "public, max-age=300, stale-if-error=21600") // cache for 5 minutes or if error for 6 hours max
|
||||
return c.HTMLBlob(http.StatusOK, buf.Bytes())
|
||||
|
||||
@@ -13,6 +13,7 @@ import (
|
||||
"github.com/getAlby/lndhub.go/lnd"
|
||||
"github.com/getsentry/sentry-go"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
"github.com/lightningnetwork/lnd/lnrpc"
|
||||
)
|
||||
|
||||
@@ -83,7 +84,14 @@ func (controller *KeySendController) KeySend(c echo.Context) error {
|
||||
|
||||
ok, err := controller.svc.BalanceCheck(c.Request().Context(), lnPayReq, userID)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to check balance",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
if !ok {
|
||||
c.Logger().Errorf("User does not have enough balance user_id:%v amount:%v", userID, lnPayReq.PayReq.NumSatoshis)
|
||||
@@ -91,7 +99,14 @@ func (controller *KeySendController) KeySend(c echo.Context) error {
|
||||
}
|
||||
invoice, err := controller.svc.AddOutgoingInvoice(c.Request().Context(), userID, "", lnPayReq)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to add invoice",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
if _, err := hex.DecodeString(invoice.DestinationPubkeyHex); err != nil || len(invoice.DestinationPubkeyHex) != common.DestinationPubkeyHexSize {
|
||||
c.Logger().Errorf("Invalid destination pubkey hex user_id:%v pubkey:%v", userID, len(invoice.DestinationPubkeyHex))
|
||||
@@ -101,6 +116,13 @@ func (controller *KeySendController) KeySend(c echo.Context) error {
|
||||
for key, value := range reqBody.CustomRecords {
|
||||
intKey, err := strconv.Atoi(key)
|
||||
if err != nil {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "invalid custom records",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
invoice.DestinationCustomRecords[uint64(intKey)] = []byte(value)
|
||||
|
||||
@@ -13,6 +13,7 @@ import (
|
||||
"github.com/getsentry/sentry-go"
|
||||
sentryecho "github.com/getsentry/sentry-go/echo"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// PayInvoiceController : Pay invoice controller struct
|
||||
@@ -57,7 +58,7 @@ func (controller *PayInvoiceController) PayInvoice(c echo.Context) error {
|
||||
paymentRequest = strings.ToLower(paymentRequest)
|
||||
decodedPaymentRequest, err := controller.svc.DecodePaymentRequest(c.Request().Context(), paymentRequest)
|
||||
if err != nil {
|
||||
if strings.Contains(err.Error(),"invoice not for current active network") {
|
||||
if strings.Contains(err.Error(), "invoice not for current active network") {
|
||||
c.Logger().Errorf("Incorrect network user_id:%v error: %v", userID, err)
|
||||
return c.JSON(http.StatusBadRequest, responses.IncorrectNetworkError)
|
||||
}
|
||||
@@ -77,6 +78,13 @@ func (controller *PayInvoiceController) PayInvoice(c echo.Context) error {
|
||||
if decodedPaymentRequest.NumSatoshis == 0 {
|
||||
amt, err := controller.svc.ParseInt(reqBody.Amount)
|
||||
if err != nil || amt <= 0 {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "invalid amount",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
lnPayReq.PayReq.NumSatoshis = amt
|
||||
@@ -91,7 +99,14 @@ func (controller *PayInvoiceController) PayInvoice(c echo.Context) error {
|
||||
|
||||
ok, err := controller.svc.BalanceCheck(c.Request().Context(), lnPayReq, userID)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "error checking balance",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.GeneralServerError)
|
||||
}
|
||||
if !ok {
|
||||
c.Logger().Errorf("User does not have enough balance user_id:%v amount:%v", userID, lnPayReq.PayReq.NumSatoshis)
|
||||
@@ -100,7 +115,14 @@ func (controller *PayInvoiceController) PayInvoice(c echo.Context) error {
|
||||
|
||||
invoice, err := controller.svc.AddOutgoingInvoice(c.Request().Context(), userID, paymentRequest, lnPayReq)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "error adding invoice",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.GeneralServerError)
|
||||
}
|
||||
sendPaymentResponse, err := controller.svc.PayInvoice(c.Request().Context(), invoice)
|
||||
if err != nil {
|
||||
|
||||
@@ -3,8 +3,10 @@ package v2controllers
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"github.com/getAlby/lndhub.go/lib/responses"
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// BalanceController : BalanceController struct
|
||||
@@ -37,7 +39,14 @@ func (controller *BalanceController) Balance(c echo.Context) error {
|
||||
userId := c.Get("UserID").(int64)
|
||||
balance, err := controller.svc.CurrentUserBalance(c.Request().Context(), userId)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to retrieve user balance",
|
||||
"lndhub_user_id": userId,
|
||||
"error": err,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
return c.JSON(http.StatusOK, &BalanceResponse{
|
||||
Balance: balance,
|
||||
|
||||
@@ -9,6 +9,7 @@ import (
|
||||
"github.com/getAlby/lndhub.go/lib/service"
|
||||
"github.com/getsentry/sentry-go"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// InvoiceController : Add invoice controller struct
|
||||
@@ -55,7 +56,14 @@ func (controller *InvoiceController) GetOutgoingInvoices(c echo.Context) error {
|
||||
|
||||
invoices, err := controller.svc.InvoicesFor(c.Request().Context(), userId, common.InvoiceTypeOutgoing)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to get invoices",
|
||||
"error": err,
|
||||
"lndhub_user_id": userId,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
|
||||
response := make([]Invoice, len(invoices))
|
||||
@@ -98,7 +106,14 @@ func (controller *InvoiceController) GetIncomingInvoices(c echo.Context) error {
|
||||
|
||||
invoices, err := controller.svc.InvoicesFor(c.Request().Context(), userId, common.InvoiceTypeIncoming)
|
||||
if err != nil {
|
||||
return err
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "failed to get invoices",
|
||||
"error": err,
|
||||
"lndhub_user_id": userId,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
|
||||
response := make([]Invoice, len(invoices))
|
||||
|
||||
@@ -12,6 +12,7 @@ import (
|
||||
"github.com/getAlby/lndhub.go/lnd"
|
||||
"github.com/getsentry/sentry-go"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
"github.com/lightningnetwork/lnd/lnrpc"
|
||||
)
|
||||
|
||||
@@ -193,6 +194,13 @@ func (controller *KeySendController) SingleKeySend(c echo.Context, reqBody *KeyS
|
||||
for key, value := range customRecords {
|
||||
intKey, err := strconv.Atoi(key)
|
||||
if err != nil {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "invalid custom records",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return nil, &responses.BadArgumentsError
|
||||
}
|
||||
invoice.DestinationCustomRecords[uint64(intKey)] = []byte(value)
|
||||
|
||||
@@ -11,6 +11,7 @@ import (
|
||||
"github.com/getsentry/sentry-go"
|
||||
sentryecho "github.com/getsentry/sentry-go/echo"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/labstack/gommon/log"
|
||||
)
|
||||
|
||||
// PayInvoiceController : Pay invoice controller struct
|
||||
@@ -66,7 +67,7 @@ func (controller *PayInvoiceController) PayInvoice(c echo.Context) error {
|
||||
paymentRequest = strings.ToLower(paymentRequest)
|
||||
decodedPaymentRequest, err := controller.svc.DecodePaymentRequest(c.Request().Context(), paymentRequest)
|
||||
if err != nil {
|
||||
if strings.Contains(err.Error(),"invoice not for current active network") {
|
||||
if strings.Contains(err.Error(), "invoice not for current active network") {
|
||||
c.Logger().Errorf("Incorrect network user_id:%v error: %v", userID, err)
|
||||
return c.JSON(http.StatusBadRequest, responses.IncorrectNetworkError)
|
||||
}
|
||||
@@ -86,12 +87,26 @@ func (controller *PayInvoiceController) PayInvoice(c echo.Context) error {
|
||||
if decodedPaymentRequest.NumSatoshis == 0 {
|
||||
amt, err := controller.svc.ParseInt(reqBody.Amount)
|
||||
if err != nil || amt <= 0 {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "invalid amount",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return c.JSON(http.StatusBadRequest, responses.BadArgumentsError)
|
||||
}
|
||||
lnPayReq.PayReq.NumSatoshis = amt
|
||||
}
|
||||
ok, err := controller.svc.BalanceCheck(c.Request().Context(), lnPayReq, userID)
|
||||
if err != nil {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "error checking balance",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return err
|
||||
}
|
||||
if !ok {
|
||||
@@ -100,6 +115,13 @@ func (controller *PayInvoiceController) PayInvoice(c echo.Context) error {
|
||||
}
|
||||
invoice, err := controller.svc.AddOutgoingInvoice(c.Request().Context(), userID, paymentRequest, lnPayReq)
|
||||
if err != nil {
|
||||
c.Logger().Errorj(
|
||||
log.JSON{
|
||||
"message": "error adding invoice",
|
||||
"error": err,
|
||||
"lndhub_user_id": userID,
|
||||
},
|
||||
)
|
||||
return err
|
||||
}
|
||||
sendPaymentResponse, err := controller.svc.PayInvoice(c.Request().Context(), invoice)
|
||||
|
||||
Reference in New Issue
Block a user