compact.js 223 Bytes edit raw blame history 1 2 3 4 5 6 7 8 9 // Inspired by: http://documentcloud.github.com/underscore/#compact 'use strict'; var filter = Array.prototype.filter; module.exports = function () { return filter.call(this, function (val) { return val != null; }); };