fix config template

This commit is contained in:
Martijn Voncken 2008-02-26 00:22:54 +00:00
parent d1b8075fe6
commit 79b9eda351
2 changed files with 3 additions and 10 deletions

View File

@ -14,7 +14,7 @@ $for group in groups:
$else:
<li><a href="/config/$page">$pages[page].title</a></li>
</ul>
</div>
<!--form block-->
<div class="panel" id="config_panel">
<h2>$form.group / $form.title</h2>

View File

@ -124,7 +124,6 @@ def get_stats():
,"max_connections_global")
async_proxy.get_dht_nodes(dict_cb('dht_nodes',stats))
async_proxy.force_call(block=True)
#log.debug(str(stats))
@ -162,7 +161,6 @@ def enhance_torrent_status(torrent_id,status):
status[key] = 0
#log.warning('torrent_status:None key in status:%s' % key)
if status.tracker == 0:
#0.6 does not raise a decent error on non-existing torrent.
raise UnknownTorrentError(torrent_id)
@ -225,19 +223,14 @@ def get_torrent_status(torrent_id):
enhance proxy.get_torrent_status with some extra data
"""
status = proxy.get_torrent_status(torrent_id,TORRENT_KEYS)
return enhance_torrent_status(torrent_id, status)
def get_torrent_list():
"""
returns a list of storified-torrent-dicts.
"""
torrent_ids = proxy.get_session_state()
torrent_dict = proxy.get_torrents_status(torrent_ids, TORRENT_KEYS)
torrent_dict = proxy.get_torrents_status(
proxy.get_session_state(), TORRENT_KEYS)
return [enhance_torrent_status(id, status)
for id, status in torrent_dict.iteritems()]