mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-11-11 06:37:21 +01:00
macaroons: add error reporting for macaroon constraints
This commit is contained in:
committed by
Olaoluwa Osuntokun
parent
679e86174f
commit
7df503575c
@@ -92,7 +92,10 @@ func getClientConn(ctx *cli.Context) *grpc.ClientConn {
|
||||
}
|
||||
|
||||
// Apply constraints to the macaroon.
|
||||
constrainedMac := macaroons.AddConstraints(mac, macConstraints...)
|
||||
constrainedMac, err := macaroons.AddConstraints(mac, macConstraints...)
|
||||
if err != nil {
|
||||
fatal(err)
|
||||
}
|
||||
|
||||
// Now we append the macaroon credentials to the dial options.
|
||||
cred := macaroons.NewMacaroonCredential(constrainedMac)
|
||||
|
||||
Reference in New Issue
Block a user