All Downloads are FREE. Search and download functionalities are using the official Maven repository.

lessjs-1.6.1.node_modules.less.node_modules.request.lib.getSafe.js Maven / Gradle / Ivy

// Safe toJSON
module.exports =
function getSafe (self, uuid) {
  if (typeof self === 'object' || typeof self === 'function') var safe = {}
  if (Array.isArray(self)) var safe = []

  var recurse = []

  Object.defineProperty(self, uuid, {})

  var attrs = Object.keys(self).filter(function (i) {
    if (i === uuid) return false
    if ( (typeof self[i] !== 'object' && typeof self[i] !== 'function') || self[i] === null) return true
    return !(Object.getOwnPropertyDescriptor(self[i], uuid))
  })


  for (var i=0;i




© 2015 - 2025 Weber Informatics LLC | Privacy Policy