mirror of
https://github.com/callebtc/electronwall.git
synced 2026-02-18 13:44:23 +01:00
allow deny
This commit is contained in:
@@ -71,7 +71,7 @@ func (app *app) dispatchChannelAcceptor(ctx context.Context) {
|
||||
|
||||
res := lnrpc.ChannelAcceptResponse{}
|
||||
if accept {
|
||||
log.Infof("✅ [channel %s] Accept channel %s", Configuration.ChannelMode, channel_info_string)
|
||||
log.Infof("✅ [channel %s] Allow channel %s", Configuration.ChannelMode, channel_info_string)
|
||||
res = lnrpc.ChannelAcceptResponse{Accept: true,
|
||||
PendingChanId: req.PendingChanId,
|
||||
CsvDelay: req.CsvDelay,
|
||||
@@ -82,7 +82,7 @@ func (app *app) dispatchChannelAcceptor(ctx context.Context) {
|
||||
}
|
||||
|
||||
} else {
|
||||
log.Infof("❌ [channel %s] Reject channel %s", Configuration.ChannelMode, channel_info_string)
|
||||
log.Infof("❌ [channel %s] Deny channel %s", Configuration.ChannelMode, channel_info_string)
|
||||
res = lnrpc.ChannelAcceptResponse{Accept: false,
|
||||
Error: Configuration.ChannelRejectMessage}
|
||||
}
|
||||
|
||||
@@ -136,10 +136,10 @@ func (app *app) interceptHtlcEvents(ctx context.Context, interceptor routerrpc.R
|
||||
IncomingCircuitKey: event.IncomingCircuitKey,
|
||||
}
|
||||
if <-decision_chan {
|
||||
log.Infof("✅ [forward %s] Accept HTLC %s", Configuration.ForwardMode, forward_info_string)
|
||||
log.Infof("✅ [forward %s] Allow HTLC %s", Configuration.ForwardMode, forward_info_string)
|
||||
response.Action = routerrpc.ResolveHoldForwardAction_RESUME
|
||||
} else {
|
||||
log.Infof("❌ [forward %s] Reject HTLC %s", Configuration.ForwardMode, forward_info_string)
|
||||
log.Infof("❌ [forward %s] Deny HTLC %s", Configuration.ForwardMode, forward_info_string)
|
||||
response.Action = routerrpc.ResolveHoldForwardAction_FAIL
|
||||
}
|
||||
err = interceptor.Send(response)
|
||||
|
||||
Reference in New Issue
Block a user