mirror of
https://github.com/ankitects/anki.git
synced 2025-09-21 15:32:23 -04:00
tolerate decks with missing mtime exported by third party software
This commit is contained in:
parent
e980ba3686
commit
38a109a5bf
2 changed files with 6 additions and 1 deletions
|
@ -76,7 +76,11 @@ mod dynfix {
|
||||||
pub struct DeckCommon {
|
pub struct DeckCommon {
|
||||||
#[serde(deserialize_with = "deserialize_number_from_string")]
|
#[serde(deserialize_with = "deserialize_number_from_string")]
|
||||||
pub(crate) id: DeckID,
|
pub(crate) id: DeckID,
|
||||||
#[serde(rename = "mod", deserialize_with = "deserialize_number_from_string")]
|
#[serde(
|
||||||
|
rename = "mod",
|
||||||
|
deserialize_with = "deserialize_number_from_string",
|
||||||
|
default
|
||||||
|
)]
|
||||||
pub(crate) mtime: TimestampSecs,
|
pub(crate) mtime: TimestampSecs,
|
||||||
pub(crate) name: String,
|
pub(crate) name: String,
|
||||||
pub(crate) usn: Usn,
|
pub(crate) usn: Usn,
|
||||||
|
|
|
@ -7,6 +7,7 @@ macro_rules! define_newtype {
|
||||||
#[repr(transparent)]
|
#[repr(transparent)]
|
||||||
#[derive(
|
#[derive(
|
||||||
Debug,
|
Debug,
|
||||||
|
Default,
|
||||||
Clone,
|
Clone,
|
||||||
Copy,
|
Copy,
|
||||||
PartialEq,
|
PartialEq,
|
||||||
|
|
Loading…
Reference in a new issue