From 208250d863f710e0d054045dd44ad816c5a00c93 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Wed, 16 Jun 2010 12:56:55 +0200 Subject: [PATCH] add hook to add playtime --- oxlib/torrent/makemetafile.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/oxlib/torrent/makemetafile.py b/oxlib/torrent/makemetafile.py index 1506f69..cc9cce1 100644 --- a/oxlib/torrent/makemetafile.py +++ b/oxlib/torrent/makemetafile.py @@ -124,7 +124,10 @@ def make_meta_file(file, url, params = {}, flag = Event(), if params.has_key('url-list') and params['url-list']: data['url-list'] = params['url-list'].split('|') - + + if params.has_key('playtime') and params['playtime']: + data['info']['playtime'] = params['playtime'] + h.write(bencode(data)) h.close()