@whitesev/utils 2.7.6 → 2.7.8

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.
@@ -6320,12 +6320,17 @@ System.register('Utils', [], (function (exports) {
6320
6320
  */
6321
6321
  getReactObj(element) {
6322
6322
  let result = {};
6323
- Object.keys(element).forEach((domPropsName) => {
6323
+ if (element == null) {
6324
+ return result;
6325
+ }
6326
+ const keys = Object.keys(element);
6327
+ keys.forEach((domPropsName) => {
6324
6328
  if (domPropsName.startsWith("__react")) {
6325
- let propsName = domPropsName.replace(/__(.+)\$.+/i, "$1");
6329
+ const propsName = domPropsName.replace(/__(.+)\$.+/i, "$1");
6330
+ const propsValue = Reflect.get(element, domPropsName);
6326
6331
  if (propsName in result) ;
6327
6332
  else {
6328
- result[propsName] = element[domPropsName];
6333
+ Reflect.set(result, propsName, propsValue);
6329
6334
  }
6330
6335
  }
6331
6336
  });