Homec4science

Validate various RRULE components and simplify logic slightly

Authored by epriestley <git@epriestley.com> on Sep 27 2016, 20:25.

Description

Validate various RRULE components and simplify logic slightly

Summary:
Ref T10747.

  • Validate that all the values are in the proper ranges (this does not yet implement some rules which take more than one value into account, e.g. BYDAY may not be in the form "+1TU" unless FREQUENCY is MONTHLY or YEARLY).
  • Use constants instead of magic strings.
  • Do array_fuse() mangling earlier.
  • Fix a couple of the TODOs around weekday stuff.
  • Implement (probably) more of the BY* rules.
  • Other minor simplification/cleanup.

Test Plan: Unit tests still pass.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T10747

Differential Revision: https://secure.phabricator.com/D16603

Details

Committed
epriestley <git@epriestley.com>Sep 28 2016, 00:02
Pushed
aubortMar 17 2017, 12:03
Parents
rPHU103f13c03f38: Rough cut of implementing some of RRULE behaviors
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHU5e5ae77b462b: Validate various RRULE components and simplify logic slightly (authored by epriestley <git@epriestley.com>).Sep 28 2016, 00:02