Skip to content

Commit 7ca8761

Browse files
committed
Changes zbase32 crate from pub to pub(crate)
1 parent 0757a55 commit 7ca8761

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lightning/src/util/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ pub(crate) mod fuzz_wrappers;
1515
pub mod events;
1616
pub mod errors;
1717
pub mod ser;
18-
pub mod zbase32;
1918
pub mod message_signing;
2019

2120
pub(crate) mod byte_utils;
2221
pub(crate) mod chacha20;
22+
pub(crate) mod zbase32;
2323
#[cfg(not(feature = "fuzztarget"))]
2424
pub(crate) mod poly1305;
2525
pub(crate) mod chacha20poly1305rfc;

lightning/src/util/zbase32.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
const ALPHABET: &'static [u8] = b"ybndrfg8ejkmcpqxot1uwisza345h769";
1212

1313
/// Encodes some bytes as a zbase32 string
14-
pub fn encode(data: &[u8]) -> String {
14+
pub(crate) fn encode(data: &[u8]) -> String {
1515
let mut ret = Vec::with_capacity((data.len() + 4) / 5 * 8);
1616

1717
for chunk in data.chunks(5) {
@@ -50,7 +50,7 @@ const INV_ALPHABET: [i8; 43] = [
5050

5151
/// Decodes a zbase32 string to the original bytes, failing if the string was not encoded by a
5252
/// proper zbase32 encoder.
53-
pub fn decode(data: &str) -> Result<Vec<u8>, ()> {
53+
pub(crate) fn decode(data: &str) -> Result<Vec<u8>, ()> {
5454
if !data.is_ascii() {
5555
return Err(());
5656
}

0 commit comments

Comments
 (0)