Remove magnetURI download support
authorChocobozzz <me@florianbigard.com>
Tue, 11 Jun 2019 08:46:33 +0000 (10:46 +0200)
committerChocobozzz <me@florianbigard.com>
Tue, 11 Jun 2019 08:46:33 +0000 (10:46 +0200)
Since most BitTorrent clients are not able to download files from it

client/src/app/shared/video/modals/video-download.component.html
client/src/app/shared/video/modals/video-download.component.ts

index dd01c13886911e85a15611040a52d2d4fa6b749c..935d013300b8ab91d838cb08d9fa6916e6cb3bb5 100644 (file)
         <input type="radio" name="download" id="download-torrent" [(ngModel)]="downloadType" value="torrent">
         <label i18n for="download-torrent">Torrent (.torrent file)</label>
       </div>
-
-      <div class="peertube-radio-container">
-        <input type="radio" name="download" id="download-magnet" [(ngModel)]="downloadType" value="magnet">
-        <label i18n for="download-magnet">Torrent (magnet link)</label>
-      </div>
     </div>
   </div>
 
index a07560f8761756552d172689f5844d21160d7abd..16f3621b4adf940619aa49a139b1cbe3d35ef9e8 100644 (file)
@@ -12,7 +12,7 @@ import { Notifier } from '@app/core'
 export class VideoDownloadComponent {
   @ViewChild('modal') modal: ElementRef
 
-  downloadType: 'direct' | 'torrent' | 'magnet' = 'torrent'
+  downloadType: 'direct' | 'torrent' = 'torrent'
   resolutionId: number | string = -1
 
   video: VideoDetails
@@ -57,9 +57,6 @@ export class VideoDownloadComponent {
 
       case 'torrent':
         return file.torrentDownloadUrl
-
-      case 'magnet':
-        return file.magnetUri
     }
   }