move pubkey checks to lnd client

This commit is contained in:
kiwiidb
2023-06-22 16:13:36 +02:00
parent c6b94e0d0d
commit def32f2d45
14 changed files with 60 additions and 46 deletions

View File

@@ -72,7 +72,7 @@ func (controller *KeySendController) KeySend(c echo.Context) error {
}
}
if reqBody.Destination == controller.svc.IdentityPubkey && reqBody.CustomRecords[strconv.Itoa(service.TLV_WALLET_ID)] == "" {
if controller.svc.LndClient.IsIdentityPubkey(reqBody.Destination) && reqBody.CustomRecords[strconv.Itoa(service.TLV_WALLET_ID)] == "" {
return c.JSON(http.StatusBadRequest, &responses.ErrorResponse{
Error: true,
Code: 8,