plumb-line-provenance 0.4.0 → 0.4.1
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/audit.mjs +2 -2
- package/package.json +1 -1
package/audit.mjs
CHANGED
|
@@ -18,12 +18,12 @@ const CLEAN_SOURCES = ["real", "semiReal", "fallback"];
|
|
|
18
18
|
* - `"source over-claim:"` — weakestSource cleaner than lineage proves
|
|
19
19
|
* - `"taint dropped:"` — a tainted lineage step but derivedFromMock is false
|
|
20
20
|
* - `"unreproducible:"` — source is "derived" but lineage is empty
|
|
21
|
-
* - `"missing meta"` — null
|
|
21
|
+
* - `"missing meta"` — input is not a plain object (null, undefined, or a non-object)
|
|
22
22
|
* @param {object|null|undefined} meta - Envelope to audit
|
|
23
23
|
* @returns {string[]} List of issue descriptions; empty means consistent
|
|
24
24
|
*/
|
|
25
25
|
export function auditMeta(meta) {
|
|
26
|
-
if (!meta) return ["missing meta"];
|
|
26
|
+
if (!meta || typeof meta !== "object" || Array.isArray(meta)) return ["missing meta"];
|
|
27
27
|
const issues = [];
|
|
28
28
|
const lineage = Array.isArray(meta.lineage) ? meta.lineage : [];
|
|
29
29
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "plumb-line-provenance",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Conservative provenance/confidence/lineage envelope with a taint-propagation combination law. Mock or low-confidence data cannot launder itself clean.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./index.mjs",
|