diff --git a/mediaweb/__init__.py b/mediaweb/__init__.py
index 81361a8..957c7e7 100644
--- a/mediaweb/__init__.py
+++ b/mediaweb/__init__.py
@@ -278,6 +278,11 @@ class MediaWeb(object):
client.rpc.core.resume_torrent([thash])
elif action == "Pause":
client.rpc.core.pause_torrent([thash])
+ elif action == "Delete":
+ if self.cache.torrents[tkey]["progress"] > 0:
+ raise Exception("Cowardly refusing to delete a torrent with progress > 0")
+ else:
+ client.rpc.core.remove_torrent(thash, True)
else:
raise cherrypy.HTTPError(404)
self.cache.refresh()
diff --git a/templates/index.html b/templates/index.html
index 0bba7ef..c8c7352 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -83,6 +83,9 @@
{% else %}
{% endif %}
+ {% if tor.progress == 0 %}
+
+ {% endif %}