Skip to content

Commit 39cce16

Browse files
authored
Merge pull request #80 from stefansundin/metadata-serialize
Add `Serialize` and `Clone` to `Metadata` struct
2 parents a3c15d9 + f050f32 commit 39cce16

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/maxminddb/lib.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ use std::net::{IpAddr, Ipv4Addr, Ipv6Addr};
99
use std::path::Path;
1010

1111
use ipnetwork::IpNetwork;
12-
use serde::{de, Deserialize};
12+
use serde::{de, Deserialize, Serialize};
1313

1414
#[cfg(feature = "mmap")]
1515
pub use memmap2::Mmap;
@@ -62,7 +62,7 @@ impl de::Error for MaxMindDBError {
6262
}
6363
}
6464

65-
#[derive(Deserialize, Debug)]
65+
#[derive(Deserialize, Serialize, Clone, Debug)]
6666
pub struct Metadata {
6767
pub binary_format_major_version: u16,
6868
pub binary_format_minor_version: u16,

0 commit comments

Comments
 (0)