get.js 1.0 KB

1234567891011121314151617181920212223242526272829303132
  1. var _Reflect$get = require("@babel/runtime-corejs3/core-js/reflect/get");
  2. var _Object$getOwnPropertyDescriptor = require("@babel/runtime-corejs3/core-js/object/get-own-property-descriptor");
  3. var superPropBase = require("./superPropBase.js");
  4. function _get(target, property, receiver) {
  5. if (typeof Reflect !== "undefined" && _Reflect$get) {
  6. module.exports = _get = _Reflect$get;
  7. module.exports["default"] = module.exports, module.exports.__esModule = true;
  8. } else {
  9. module.exports = _get = function _get(target, property, receiver) {
  10. var base = superPropBase(target, property);
  11. if (!base) return;
  12. var desc = _Object$getOwnPropertyDescriptor(base, property);
  13. if (desc.get) {
  14. return desc.get.call(receiver);
  15. }
  16. return desc.value;
  17. };
  18. module.exports["default"] = module.exports, module.exports.__esModule = true;
  19. }
  20. return _get(target, property, receiver || target);
  21. }
  22. module.exports = _get;
  23. module.exports["default"] = module.exports, module.exports.__esModule = true;