@onlyworlds/sdk 4.102.4 → 4.102.5
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.
- package/CHANGELOG.md +6 -0
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,12 @@ earlier history lives in git log only.
|
|
|
5
5
|
|
|
6
6
|
## [Unreleased]
|
|
7
7
|
|
|
8
|
+
## [4.102.5] - 2026-10-29
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
|
|
12
|
+
- **`readCalendarConfig` refuses an empty `grain`.** The calendar profile requires `grain` as a string, and an empty string is no grain: the reader took `grain: ""` as a calendar while `validateCalendarConfig` already refused it. It now returns `null` (show bare numbers), as the Python package's reader does from 0.84.3; schema-dist's next serial carries the case.
|
|
13
|
+
|
|
8
14
|
## [4.102.4] - 2026-10-29
|
|
9
15
|
|
|
10
16
|
### Fixed
|
package/dist/index.js
CHANGED
|
@@ -6094,7 +6094,7 @@ function validateCalendarConfig(cfg) {
|
|
|
6094
6094
|
function readCalendarConfig(value) {
|
|
6095
6095
|
if (typeof value !== "object" || value === null) return null;
|
|
6096
6096
|
const cfg = value;
|
|
6097
|
-
if (cfg.version !== 1 && cfg.version !== 2 || typeof cfg.grain !== "string") return null;
|
|
6097
|
+
if (cfg.version !== 1 && cfg.version !== 2 || typeof cfg.grain !== "string" || cfg.grain === "") return null;
|
|
6098
6098
|
const months = cfg.bundles?.months;
|
|
6099
6099
|
if (months && (!Array.isArray(months.names) || !Array.isArray(months.lengths) || months.names.length !== months.lengths.length || months.names.length === 0 || !months.names.every(isString))) return null;
|
|
6100
6100
|
if (cfg.eras != null && !Array.isArray(cfg.eras)) return null;
|