# del self.peers[site]
# Start the DHT lookup
- lookupDefer = self.manager.dht.getValue(key)
+ lookupDefer = self.manager.dht.get(key)
lookupDefer.addBoth(self._getDHTPieces, key)
def _getDHTPieces(self, results, key):
headers = {}
if response.headers.hasHeader('last-modified'):
headers['last-modified'] = response.headers.getHeader('last-modified')
- resp = Response(200, {}, self.stream)
+ resp = Response(200, headers, self.stream)
df.callback(resp)
# Read the response stream to the file
@type cache_dir: L{twisted.python.filepath.FilePath}
@ivar cache_dir: the directory to use for storing all files
- @type dht: L{interfaces.IDHT}
+ @type dht: L{DHTManager.DHT}
@ivar dht: the DHT instance
@type stats: L{stats.StatsLogger}
@ivar stats: the statistics logger to record sent data to