mirror of
https://github.com/transmission/transmission.git
synced 2025-12-24 12:28:52 +00:00
#4176 Add torrent by info hash
This commit is contained in:
@@ -249,6 +249,9 @@ TransmissionRemote.prototype =
|
||||
},
|
||||
addTorrentByUrl: function( url, options ) {
|
||||
var remote = this;
|
||||
if(url.match(/^[0-9a-f]{40}$/i)) {
|
||||
url = 'magnet:?xt=urn:btih:'+url;
|
||||
}
|
||||
var o = {
|
||||
method: 'torrent-add',
|
||||
arguments: {
|
||||
|
||||
Reference in New Issue
Block a user