diff --git a/core/src/main/groovy/com/muwire/core/files/PersisterService.groovy b/core/src/main/groovy/com/muwire/core/files/PersisterService.groovy index 636c40ef..adadab3c 100644 --- a/core/src/main/groovy/com/muwire/core/files/PersisterService.groovy +++ b/core/src/main/groovy/com/muwire/core/files/PersisterService.groovy @@ -137,7 +137,7 @@ class PersisterService extends Service { private def toJson(File f, SharedFile sf) { def json = [:] json.file = Base64.encode DataUtil.encodei18nString(f.toString()) - json.length = f.length() + json.length = sf.getCachedLength() InfoHash ih = sf.getInfoHash() json.infoHash = Base64.encode ih.getRoot() json.pieceSize = sf.getPieceSize()