TOTorrent torrent = dm.getTorrent();
if (torrent != null) {
try {
TRHost host = ci.azureus_core.getTrackerHost();
TRHostTorrent existing = host.getHostTorrent( torrent );
if ( existing == null ){
host.publishTorrent(torrent);
}else{
try{
existing.remove();
}catch( Throwable e ){
e.printStackTrace();
}
}
} catch (TRHostException e) {
e.printStackTrace(ci.out);
return false;
}
return true;
}
return false;