From bc16f6e7e6bbd145d1d0f541f98d74061f7fa966 Mon Sep 17 00:00:00 2001 From: Fredrik Meringdal Date: Wed, 3 Feb 2021 22:42:33 +0100 Subject: docs --- src/parse_options.rs | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'src/parse_options.rs') diff --git a/src/parse_options.rs b/src/parse_options.rs index 7953887..f6af1d9 100644 --- a/src/parse_options.rs +++ b/src/parse_options.rs @@ -1,4 +1,6 @@ -use crate::options::{Frequenzy, NWeekday, NWeekdayIdentifier, Options, ParsedOptions, RRuleParseError}; +use crate::options::{ + Frequenzy, NWeekday, NWeekdayIdentifier, Options, ParsedOptions, RRuleParseError, +}; use crate::utils::is_some_and_not_empty; use chrono::prelude::*; use chrono_tz::{Tz, UTC}; @@ -69,8 +71,10 @@ pub fn parse_options(options: &Options) -> Result { - partial_options.byweekday = - Some(vec![NWeekday::new(dtstart.weekday() as usize, NWeekdayIdentifier::Every)]); + partial_options.byweekday = Some(vec![NWeekday::new( + dtstart.weekday() as usize, + NWeekdayIdentifier::Every, + )]); } _ => (), }; @@ -100,9 +104,7 @@ pub fn parse_options(options: &Options) -> Result { - byweekday.push(wday.weekday) - } + NWeekdayIdentifier::Every => byweekday.push(wday.weekday), NWeekdayIdentifier::Identifier(n) => { bynweekday.push(vec![wday.weekday as isize, n]); } -- cgit v1.2.3