Skip to content

Commit f940c01

Browse files
committed
run fmt
1 parent 312a323 commit f940c01

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/bson.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1106,7 +1106,10 @@ impl Binary {
11061106
/// Creates a [`Binary`] from a base64 string and optional [`BinarySubtype`]. If the
11071107
/// `subtype` argument is `None`, the [`Binary`] constructed will default to
11081108
/// [`BinarySubtype::Generic`].
1109-
pub fn from_base64(input: &str, subtype: impl Into<Option<BinarySubtype>>) -> Result<Self, DecodeError> {
1109+
pub fn from_base64(
1110+
input: &str,
1111+
subtype: impl Into<Option<BinarySubtype>>,
1112+
) -> Result<Self, DecodeError> {
11101113
let bytes = base64::decode(input)?;
11111114
let subtype = match subtype.into() {
11121115
Some(s) => s,

src/tests/modules/binary.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::{tests::LOCK, Binary, spec::BinarySubtype};
1+
use crate::{spec::BinarySubtype, tests::LOCK, Binary};
22

33
#[test]
44
fn binary_from_base64() {
@@ -16,7 +16,7 @@ fn binary_from_base64() {
1616
let produced = Binary::from_base64("", Some(BinarySubtype::Uuid)).unwrap();
1717
let expected = Binary {
1818
bytes: "".as_bytes().to_vec(),
19-
subtype: BinarySubtype::Uuid
19+
subtype: BinarySubtype::Uuid,
2020
};
2121
assert_eq!(produced, expected);
2222
}

0 commit comments

Comments
 (0)