💾 Archived View for lists.flounder.online › patches › threads › 20210317214420.11511-1-johann@qwertq… captured on 2022-04-28 at 19:25:07. Gemini links have been rewritten to link to archived content

View Raw

More Information

-=-=-=-=-=-=-

[PATCH mygit 1/2] simplify code

[PATCH mygit 1/2] simplify code

From: johann@qwertqwefsday.eu

Date: Wed, 17 Mar 2021 22:44:19 +0100

Message-Id: 20210317214420.11511-1-johann@qwertqwefsday.eu

To: <~aw/patches@lists.sr.ht>

Cc: "Johann150" <johann@qwertqwefsday.eu>

Reply

Export

--------------------------------------

From: Johann150 <johann@qwertqwefsday.eu>

unnecessary to specify the name twice if it is identical to the field name

---

src/main.rs | 4 ++--

1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/main.rs b/src/main.rs

index 5f2c741..754a0c6 100644

--- a/src/main.rs

+++ b/src/main.rs

@@ -225,7 +225,7 @@ async fn repo_log(req: Request<()>) -> tide::Result {

let tmpl = RepoLogTemplate {

repo: &repo,

commits,

- branch: branch,

+ branch,

};

Ok(tmpl.into())

}

@@ -289,7 +289,7 @@ async fn repo_tree(req: Request<()>) -> tide::Result {

let tmpl = RepoTreeTemplate {

repo: &repo,

tree,

- spec: spec,

+ spec,

};

Ok(tmpl.into())

}

--

2.20.1