Anons79 Mini Shell

Directory : /home/aplikasiposinfo/www/rscmmaryam.aplikasipos.info/node_modules/collect.js/dist/methods/
Upload File :
Current File : /home/aplikasiposinfo/www/rscmmaryam.aplikasipos.info/node_modules/collect.js/dist/methods/map.js

'use strict';

module.exports = function map(fn) {
  var _this = this;

  if (Array.isArray(this.items)) {
    return new this.constructor(this.items.map(fn));
  }

  var collection = {};

  Object.keys(this.items).forEach(function (key) {
    collection[key] = fn(_this.items[key], key);
  });

  return new this.constructor(collection);
};

Anons79 File Manager Version 1.0, Coded By Anons79
Email: [email protected]