You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
657 B

4 years ago
  1. var LazyWrapper = require('./_LazyWrapper'),
  2. copyArray = require('./_copyArray');
  3. /**
  4. * Creates a clone of the lazy wrapper object.
  5. *
  6. * @private
  7. * @name clone
  8. * @memberOf LazyWrapper
  9. * @returns {Object} Returns the cloned `LazyWrapper` object.
  10. */
  11. function lazyClone() {
  12. var result = new LazyWrapper(this.__wrapped__);
  13. result.__actions__ = copyArray(this.__actions__);
  14. result.__dir__ = this.__dir__;
  15. result.__filtered__ = this.__filtered__;
  16. result.__iteratees__ = copyArray(this.__iteratees__);
  17. result.__takeCount__ = this.__takeCount__;
  18. result.__views__ = copyArray(this.__views__);
  19. return result;
  20. }
  21. module.exports = lazyClone;