@rjsf/utils 5.23.1 → 5.23.2

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/dist/index.js CHANGED
@@ -137,13 +137,16 @@ module.exports = __toCommonJS(src_exports);
137
137
 
138
138
  // src/isObject.ts
139
139
  function isObject(thing) {
140
- if (typeof File !== "undefined" && thing instanceof File) {
140
+ if (typeof thing !== "object" || thing === null) {
141
141
  return false;
142
142
  }
143
- if (typeof Date !== "undefined" && thing instanceof Date) {
143
+ if (typeof thing.lastModified === "number" && typeof File !== "undefined" && thing instanceof File) {
144
144
  return false;
145
145
  }
146
- return typeof thing === "object" && thing !== null && !Array.isArray(thing);
146
+ if (typeof thing.getMonth === "function" && typeof Date !== "undefined" && thing instanceof Date) {
147
+ return false;
148
+ }
149
+ return !Array.isArray(thing);
147
150
  }
148
151
 
149
152
  // src/allowAdditionalItems.ts