aboutsummaryrefslogtreecommitdiff
path: root/ui/src/app/downloads.pipe.ts
diff options
context:
space:
mode:
authorAlex Shnitman <alexta69@gmail.com>2022-01-14 09:11:03 +0200
committerAlex Shnitman <alexta69@gmail.com>2022-01-14 09:11:03 +0200
commit622ca428e3b38084a35f43552b0fb504416078a7 (patch)
tree88b359fa4c4bad163a1c387fcd61e19572ef9593 /ui/src/app/downloads.pipe.ts
parentMerge pull request #99 from Erazor2/RealRetry (diff)
downloadmetube-622ca428e3b38084a35f43552b0fb504416078a7.tar.gz
metube-622ca428e3b38084a35f43552b0fb504416078a7.tar.bz2
metube-622ca428e3b38084a35f43552b0fb504416078a7.zip
encode download links (closes #104)
Diffstat (limited to 'ui/src/app/downloads.pipe.ts')
-rw-r--r--ui/src/app/downloads.pipe.ts9
1 files changed, 9 insertions, 0 deletions
diff --git a/ui/src/app/downloads.pipe.ts b/ui/src/app/downloads.pipe.ts
index d4a1654..cb3bf92 100644
--- a/ui/src/app/downloads.pipe.ts
+++ b/ui/src/app/downloads.pipe.ts
@@ -35,3 +35,12 @@ export class SpeedPipe implements PipeTransform {
return parseFloat((value / Math.pow(k, i)).toFixed(dm)) + ' ' + sizes[i];
}
}
+
+@Pipe({
+ name: 'encodeURIComponent'
+})
+export class EncodeURIComponent implements PipeTransform {
+ transform(value: string, ...args: any[]): any {
+ return encodeURIComponent(value);
+ }
+}
bgstack15