send reject message when we don't have piece

This commit is contained in:
Feross Aboukhadijeh 2014-06-03 21:17:16 -07:00
parent d3d937fe27
commit 9562a84c5a
1 changed files with 1 additions and 0 deletions

View File

@ -137,6 +137,7 @@ module.exports = function (metadata) {
ut_metadata.prototype._onRequest = function (piece) {
if (!this._metadataComplete) {
this._reject(piece)
return
}
var start = piece * PIECE_LENGTH