What changed, and why it matters
This commit only fixes a misleading comment for the InitPayment method. No code behavior was changed, so there is no security impact.
No action needed; this is a documentation-only change.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The diff updates the GoDoc comment for the ControlTower.InitPayment method in routing/control_tower.go. The old comment incorrectly stated that the method checks for an existing succeeded payment; the new comment states that it initializes a new payment and notifies subscribers. No executable code, logic, or data flow was modified.
Changed components
routing/control_tower.goInspect captured patch +2 / −2
diff --git a/routing/control_tower.go b/routing/control_tower.go
index dd984c9..fcbfbe8 100644
--- a/routing/control_tower.go
+++ b/routing/control_tower.go
@@ -47,8 +47,8 @@ type DBMPPayment interface {
// restarts. Payments are transitioned through various payment states, and the
// ControlTower interface provides access to driving the state transitions.
type ControlTower interface {
- // This method checks that no succeeded payment exist for this payment
- // hash.
+ // InitPayment initializes a new payment with the given payment hash and
+ // also notifies subscribers of the payment creation.
InitPayment(lntypes.Hash, *paymentsdb.PaymentCreationInfo) error
// DeleteFailedAttempts removes all failed HTLCs from the db. It should
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.