From 46b97dc293b42deb2ff9193181422a694ab708ef Mon Sep 17 00:00:00 2001 From: fabuloso Date: Thu, 22 Jul 2021 09:12:27 +0200 Subject: [PATCH] Use ceo instead of name in Company --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 4af16d2..a3dbf2c 100644 --- a/README.md +++ b/README.md @@ -6192,7 +6192,7 @@ impl Company { fn new(name: &str, ceo: &str) -> Self { let ceo = match ceo { "" => None, - name => Some(name.to_string()), + ceo => Some(ceo.to_string()), }; // ceo is decided, so now we return Self Self { name: name.to_string(), @@ -6258,7 +6258,7 @@ impl Company { fn new(name: &str, ceo: &str) -> Self { let ceo = match ceo { "" => None, - name => Some(name.to_string()), + ceo => Some(ceo.to_string()), }; Self { name: name.to_string(),