get the SHA corresponding to id at the HEAD of options.branch

@access private
@param {String} id
@param {Function} callback called with (err, result)
508230
function _getSHA(id, callback) {
        repo.contents("").fetch({
            ref: options.branch
        }, function(err, res) {
            if (err) return callback(err);
            var sha = res.reduce(function(previousValue, item) {
                return item.name === id ? item.sha : previousValue;
            }, "");
            callback(err, sha);
        });
    }
993444
def get_by_id(self, id):
        """"""
        return self.user_cls(id=id, password='secret' + str(id))
1194827
function findIndex(queue, id) {
  var i = queue.length;
  while (i-- && queue[i].id !== id);
  return i;
}
291307
def get_branch(db, root_hash, key):
    
    validate_is_bytes(key)

    return tuple(_get_branch(db, root_hash, encode_to_bin(key)))
1174243
def get_by_id(id)
      accts = @accounts.select {|acct| acct.uuid == id }

      if accts.size == 0
        raise KeyError, "account with id #{id} unknown"
      elsif accts.size > 1
        logger.warn "multiple accounts with same UUID found", uuid: id
      end

      accts[0]
    end
215790
function(id, head, tail) {
        head = head || '';
        tail = tail || id;

        if (this.arch.hasNode(id)) return Q.resolve(id);
        if (head === id) return Q.reject(UTIL.format('Node "%s" not found', id));

        var parts = tail.split(PATH.dirSep),
            p = parts.shift();
        head = (head? [head, p] : [p]).join(PATH.dirSep);
        tail = parts.join(PATH.dirSep);

        var _this = this,
            magicHead = head + '*';
        if (!this.arch.hasNode(magicHead)) {
            return this.findNode(id, head, tail);
        }

        return this.process(magicHead).then(function() {
            return _this.findNode(id, head, tail);
        });
    }
739052
function (callback) {
    this.repository.getNewId(function(err, newId) {
      if (err) {
        debug(err);
        return callback(err);
      }
      callback(null, newId);
    });
  }
281903
function getUserOrganizationId (id, cb) {
      let promise = null
      if (typeof cb !== 'function') [promise, cb] = asyncify()

      const sqlQuery = SQL`
        SELECT org_id
        FROM users
        WHERE id = ${id}
      `
      db.query(sqlQuery, function (err, result) {
        if (err) return cb(Boom.badImplementation(err))
        if (result.rowCount === 0) return cb(Boom.notFound())

        return cb(null, result.rows[0].org_id)
      })

      return promise
    }
497652
def config_callback(id, option, value)
      ret = Weechat::Hooks::Config.find_by_id(id).call(option, value)
    end
1149218
def _get_by_id_async(cls, id, parent=None, app=None, namespace=None,
                       **ctx_options):
    
    key = Key(cls._get_kind(), id, parent=parent, app=app, namespace=namespace)
    return key.get_async(**ctx_options)
100817
def get(cls, id):
        

        # cached?
        if CACHE:
            if id in _cache['Pool']:
                log.debug('cache hit for pool %d' % id)
                return _cache['Pool'][id]
            log.debug('cache miss for pool %d' % id)

        try:
            pool = Pool.list({'id': id})[0]
        except (IndexError, KeyError):
            raise NipapNonExistentError('no pool with ID ' + str(id) + ' found')

        _cache['Pool'][id] = pool
        return pool
1103186
@SuppressWarnings("unchecked")
  public <C extends CDACallback<T>> C one(String id, C callback) {
    return (C) Callbacks.subscribeAsync(baseQuery().one(id), callback, client);
  }
170479
function getChainIndexById(id, sequence){
    return sequence.map(function(el){
      return el._id;
    }).indexOf(id);
  }
477841
def get(self, id, **options):
        ''''''
        if not self._item_path:
            raise AttributeError('get is not available for %s' % self._item_name)
        target = self._item_path % id
        json_data = self._redmine.get(target, **options)
        data = self._redmine.unwrap_json(self._item_type, json_data)
        data['_source_path'] = target
        return self._objectify(data=data)
25852
def get(id)
      return unless id
      with_redis { |redis| redis.get(redis_key_for(id)).try { |data| load(data) } }
    end
10039
def get(self, id, param):
        
        assert isinstance(id, basestring)
        assert isinstance(param, basestring)
        return self.params_.get(param, {}).get(id)
304413
function(id) {
      if (id == null) return void 0;
      return this._byId[id.id != null ? id.id : id];
    }