From 76246837108cf0e13fa5d3b6711db1565abb549e Mon Sep 17 00:00:00 2001 From: Calum Lind Date: Sat, 18 Jan 2014 21:48:41 +0000 Subject: [PATCH] Add torrent.get_magnet_uri() to return generated magnet uri --- deluge/core/torrent.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/deluge/core/torrent.py b/deluge/core/torrent.py index 484feae75..743cc359f 100644 --- a/deluge/core/torrent.py +++ b/deluge/core/torrent.py @@ -621,6 +621,10 @@ class Torrent(object): return host return "" + def get_magnet_uri(self): + """Returns a magnet uri for this torrent""" + return lt.make_magnet_uri(self.handle) + def get_status(self, keys, diff=False, update=False, all_keys=False): """ Returns the status of the torrent based on the keys provided