diff options
| author | Teddy Wing | 2021-05-22 18:30:48 +0200 | 
|---|---|---|
| committer | Teddy Wing | 2021-05-22 18:30:48 +0200 | 
| commit | ad06bc6172b2c9204629ccead723d86b388ff364 (patch) | |
| tree | 2b90bfebed64767438195283eadc8dec1df86bbb /src | |
| parent | 8da3502b3f065a10e5faf4cd24bc988d843d798e (diff) | |
| download | google-calendar-rsvp-ad06bc6172b2c9204629ccead723d86b388ff364.tar.bz2 | |
Rename `email` to `should_read_email`
Make the variable's usage clearer.
Diffstat (limited to 'src')
| -rw-r--r-- | src/main.rs | 6 | 
1 files changed, 3 insertions, 3 deletions
| diff --git a/src/main.rs b/src/main.rs index 1d3595a..c71a44d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -40,7 +40,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {      let args: Vec<String> = env::args().collect();      let mut action_opt: Option<EventResponseStatus> = None; -    let mut email = false; +    let mut should_read_email = false;      let mut email_eid = String::new();      let mut event_ids = Vec::new(); @@ -54,7 +54,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {                  action_opt = Some(EventResponseStatus::Tentative),              "--email" => -                email = true, +                should_read_email = true,              id =>                  event_ids.push(id), @@ -70,7 +70,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {          },      }; -    if email { +    if should_read_email {          let mut stdin = io::stdin();          let mut email_input: Vec<u8> = Vec::new();          stdin.read_to_end(&mut email_input)?; | 
