aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/schema.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/schema.rs b/src/schema.rs
index eae60af..81bfc1b 100644
--- a/src/schema.rs
+++ b/src/schema.rs
@@ -34,7 +34,7 @@ fn block_parser(path: String) -> u64 {
34fn last_block_content() -> Option<String> { 34fn last_block_content() -> Option<String> {
35 let blocks = read_block_name().unwrap(); 35 let blocks = read_block_name().unwrap();
36 36
37 if blocks.len() == 0 { 37 if blocks.is_empty() {
38 return None; 38 return None;
39 } 39 }
40 40
@@ -173,6 +173,12 @@ impl Db {
173 } 173 }
174} 174}
175 175
176impl Default for Db {
177 fn default() -> Self {
178 Self::new()
179 }
180}
181
176/// A transaction between `source` and `target` that moves `amount` 182/// A transaction between `source` and `target` that moves `amount`
177#[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] 183#[derive(Serialize, Deserialize, Debug, Clone, PartialEq)]
178pub struct Transaction { 184pub struct Transaction {