@fabriktor/fx 0.0.79 → 0.0.80

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -426,14 +426,14 @@ function validateProgramStart(opts) {
426
426
  msg: msgTimezoneInvalid,
427
427
  });
428
428
  }
429
- const current_day = sameCalendarDay(opts.start, now);
430
- if (!current_day && compareLocalDate(opts.start, now) < 0) {
429
+ const comparison = compareLocalDate(opts.start, now);
430
+ if (comparison < 0) {
431
431
  throw errValidation({
432
432
  field: "in",
433
433
  msg: msgProgramStartPast,
434
434
  });
435
435
  }
436
- return current_day;
436
+ return comparison === 0;
437
437
  }
438
438
  function validateDuration(v, field) {
439
439
  if (!Number.isFinite(v) || !Number.isInteger(v) || v < 0) {
@@ -483,9 +483,6 @@ function normalizeRecurrenceEnd(opts) {
483
483
  });
484
484
  }
485
485
  }
486
- function sameCalendarDay(a, b) {
487
- return a.y === b.y && a.m === b.m && a.d === b.d;
488
- }
489
486
  function locationTimezone(location, field) {
490
487
  const out = location.timezone.trim();
491
488
  if (out === "") {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fabriktor/fx",
3
- "version": "0.0.79",
3
+ "version": "0.0.80",
4
4
  "description": "![Fabriktor Logo](./img/fabriktor-character.gif)",
5
5
  "type": "module",
6
6
  "exports": {