From 6ace7f8eeac8e9b70fbfb1d7865626330a6c7f10 Mon Sep 17 00:00:00 2001 From: Stephan Dilly Date: Mon, 24 May 2021 00:35:00 +0200 Subject: [PATCH] cleanup --- asyncgit/src/sync/staging/stage_tracked.rs | 1 - asyncgit/src/sync/tree.rs | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/asyncgit/src/sync/staging/stage_tracked.rs b/asyncgit/src/sync/staging/stage_tracked.rs index efc348a0..a05647e7 100644 --- a/asyncgit/src/sync/staging/stage_tracked.rs +++ b/asyncgit/src/sync/staging/stage_tracked.rs @@ -51,7 +51,6 @@ pub fn stage_lines( idx.id = blob_id; idx.file_size = u32::try_conv(new_content.as_bytes().len())?; - //TODO: can we simply use add_frombuffer? index.add(&idx)?; index.write()?; diff --git a/asyncgit/src/sync/tree.rs b/asyncgit/src/sync/tree.rs index 68c49b59..4ee4087b 100644 --- a/asyncgit/src/sync/tree.rs +++ b/asyncgit/src/sync/tree.rs @@ -11,7 +11,7 @@ use std::{ }; /// `tree_files` returns a list of `FileTree` -#[derive(Debug, PartialEq)] +#[derive(Debug, PartialEq, Clone)] pub struct TreeFile { /// path of this file pub path: PathBuf,