]> git.bitcoin.ninja Git - rust-lightning/commitdiff
Export error type instead of entire modules
authorElias Rohrer <ero@tnull.de>
Fri, 9 Sep 2022 11:19:43 +0000 (13:19 +0200)
committerElias Rohrer <ero@tnull.de>
Mon, 12 Sep 2022 18:25:54 +0000 (20:25 +0200)
Previously the `error` and `processing` modules have been `pub`, leading
to them being included in the docs, altough (almost) empty.

Instead, we now `pub use` the `GraphSyncError` directly, cleaning up the
docs.

lightning-rapid-gossip-sync/src/lib.rs

index 70758e1fe07e6a5ae0f5a430ac374ee3ae5708be..9005665b3dc14acfae534e9806906712337e2d7e 100644 (file)
@@ -75,13 +75,13 @@ use std::sync::atomic::{AtomicBool, Ordering};
 use lightning::routing::gossip::NetworkGraph;
 use lightning::util::logger::Logger;
 
-use crate::error::GraphSyncError;
+pub use crate::error::GraphSyncError;
 
 /// Error types that these functions can return
-pub mod error;
+mod error;
 
 /// Core functionality of this crate
-pub mod processing;
+mod processing;
 
 /// Rapid Gossip Sync struct
 /// See [crate-level documentation] for usage.