plugins: lsps: use transport specific error
What changed, and why it matters
This is a tiny code cleanup in a Lightning plugin. The developer replaced a generic Rust error type with a project-specific error type in two function signatures. There is no functional change visible in the diff, no bug fix, and no security-relevant behavior change.
No action needed. This commit does not appear security relevant.
Security signals we found
No strong security signals were identified.
Evidence from the diff
In plugins/lsps-plugin/src/core/transport.rs, the Transport trait’s send and notify methods change their return type from core::result::Result
Changed components
plugins/lsps-plugin/src/core/transport.rsInspect captured patch +2 / −2
diff --git a/plugins/lsps-plugin/src/core/transport.rs b/plugins/lsps-plugin/src/core/transport.rs
index 4d0671c9..5e5ce749 100644
--- a/plugins/lsps-plugin/src/core/transport.rs
+++ b/plugins/lsps-plugin/src/core/transport.rs
@@ -39,8 +39,8 @@ pub type Result<T> = std::result::Result<T, Error>;
/// request over some transport mechanism (RPC, Bolt8, etc.)
#[async_trait]
pub trait Transport: Send + Sync {
- async fn send(&self, peer: &PublicKey, request: String) -> core::result::Result<String, Error>;
- async fn notify(&self, peer: &PublicKey, request: String) -> core::result::Result<(), Error>;
+ async fn send(&self, peer: &PublicKey, request: String) -> Result<String>;
+ async fn notify(&self, peer: &PublicKey, request: String) -> Result<()>;
}
/// A typed JSON-RPC client that works with any transport implementation.
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.