code: function(err, res) {
      var queuedLink = null;
      if (res && res.hits && res.hits.hits.length) {
        var hit = res.hits.hits[0]._source;
        var queued = hit.queued;
        queuedLink = { uri: hit.uri, queued: queued, total: res.hits.total };
        queued.lastAttempt = new Date().toISOString();
        queued.attempts = queued.attempts + 1;
        hit.queued = queued;
  
        // update accesses
        contentLib.indexContentItem(hit, {state: 'queued', member: queued.member}, function(err, res) {
          // process the link
          if (!err) {
            callback(null, queuedLink);
          } else {
            utils.passingError(err);
          }
        });
      } else {
        callback(err, null);
      }
    }
docs: function to process the link