var findInfoArrayStatus = function (cluster, index, ) { var status; if (global.infoArray && global.infoArray.length > 0) { _.find(global.infoArray, function (file) { if (file.cluster === cluster && file.index === index) { status = file.status } }); } return status; }
/** * Given a docs array and an id, return the document whose id matches, or null if none is found */ function findById (docs, id) { return _.find(docs, function (doc) { return doc._id === id; }) || null; }
function findManualSwitchCluster(clusterName) { var name = f.existy(clusterName) ? clusterName : DEFAULT_CLUSTER_NAME; return _.find(clusters, function(cluster) { return _.isEqual(cluster.name, name); }); }
//PUT to /api/<objects>/:id $scope.language.$update(function () { var destLanguage = _.find($scope.$root.languages, function (language) { return language.objectId == $scope.language.objectId; }); if (_.isObject(destLanguage)) { _.extend(destLanguage, $scope.language); } //$alert(content, title, alertType, placement) $alert('saved', '', 'success'); //$state.go('languages.list'); });
locateFromFile (file) { const dir = path.dirname (file) return this.cache[dir] || ( this.cache[dir] = _.find (locator.parentDirsOf (file), dir => locator.isFile (path.join (dir, 'package.json')))) }
r.db('nakiva').table('skills').run().then(function(data) { var skills; skills = _.find(data[0].skills, function(skillData) { return skillData.id == skillId; }); callback(skills); });
/* Once semantics */ var once = function (then) { if (!_.find (queue, function (f) { return f.onceWrapped_ === then })) { read (_.extend (function callee (v) { _.off (self, callee); then (v) }, { onceWrapped_: then })) } }
/* Locates NPM module path */ locate (name, where) { return _.find (locator.parentDirsOf (where || process.cwd ()), dir => locator.isDirectory (path.join (dir, 'node_modules', name))) }
_.find(this.users, function(user) { if (user.user_id.equals(userId)) { return user; } })
getError(code) { return _.find(messages.errorMessages, function(errorMessage) { return errorMessage.code == code; }); }
nm_.find(columns, function(displayName, column) { if (!nmValidator.isNull(instance.get(column))) { valid = true; return true; } });
_.find( AddressList, item => item.ShortKey === nameKey.toUpperCase() )
r.db('nakiva').table('companies').run().then(function(data) { var orgnisation; orgnisation = _.find(data[0].orgs, function(orgData) { return orgData.id == orgId; }); callback(orgnisation); });
/** * Given a docs array and an id, return the document whose id matches, or null if none is found */ function findById (docs, id) { return _.find(docs, function (doc) { return doc._id === id; }) || null; }