@kalutskii/foundation 0.6.24 → 0.6.25

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/README.md CHANGED
@@ -285,6 +285,7 @@ The package exports all public APIs from a single entrypoint:
285
285
  ```bash
286
286
  bun install
287
287
  bun run lint
288
+ bun run test
288
289
  bun run typecheck
289
290
  bun run build
290
291
  ```
package/dist/index.d.ts CHANGED
@@ -493,8 +493,8 @@ declare const parseQueryValue: (value: unknown) => unknown;
493
493
  declare const asQuery: <T extends z.ZodTypeAny>(schema: T) => z.ZodPreprocess<T>;
494
494
 
495
495
  /**
496
- * Checks if the given value is a plain object (i.e., an object
497
- * that is not null, not an array, and has a prototype of Object).
496
+ * Checks whether a value is a plain record backed by `Object.prototype`.
497
+ * Arrays, null, dates, collections, and custom class instances are rejected.
498
498
  */
499
499
  declare const isPlainObject: (value: unknown) => value is Record<string, unknown>;
500
500
 
package/dist/index.js CHANGED
@@ -271,7 +271,7 @@ import z4 from "zod";
271
271
 
272
272
  // src/zod-validation/zod-validation.utilities.ts
273
273
  var isPlainObject = (value) => {
274
- return typeof value === "object" && value !== null && !Array.isArray(value);
274
+ return typeof value === "object" && value !== null && !Array.isArray(value) && Object.getPrototypeOf(value) === Object.prototype;
275
275
  };
276
276
 
277
277
  // src/zod-validation/zod-validation.parsing.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kalutskii/foundation",
3
- "version": "0.6.24",
3
+ "version": "0.6.25",
4
4
  "description": "Typescript collection of most common utilities, schemas and functions among private projects.",
5
5
  "type": "module",
6
6
  "repository": {