diff options
author | Rigel Kent <sendmemail@rigelk.eu> | 2018-10-12 18:12:39 +0200 |
---|---|---|
committer | Rigel Kent <sendmemail@rigelk.eu> | 2018-10-13 11:53:48 +0200 |
commit | ed638e5325096ef580da20f370ac61c59cd48cf7 (patch) | |
tree | 8ad4c1001efb3adc3946a6b6c9a3c1ed1f557995 /client/src/app/+my-account/my-account-settings/my-account-video-settings/my-account-video-settings.component.ts | |
parent | 64cc5e8575fda47b281ae20abf0020e27fc8ce7c (diff) | |
download | PeerTube-ed638e5325096ef580da20f370ac61c59cd48cf7.tar.gz PeerTube-ed638e5325096ef580da20f370ac61c59cd48cf7.tar.zst PeerTube-ed638e5325096ef580da20f370ac61c59cd48cf7.zip |
move to boolean switch
Diffstat (limited to 'client/src/app/+my-account/my-account-settings/my-account-video-settings/my-account-video-settings.component.ts')
-rw-r--r-- | client/src/app/+my-account/my-account-settings/my-account-video-settings/my-account-video-settings.component.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/client/src/app/+my-account/my-account-settings/my-account-video-settings/my-account-video-settings.component.ts b/client/src/app/+my-account/my-account-settings/my-account-video-settings/my-account-video-settings.component.ts index 9e711a227..6c9a7ce75 100644 --- a/client/src/app/+my-account/my-account-settings/my-account-video-settings/my-account-video-settings.component.ts +++ b/client/src/app/+my-account/my-account-settings/my-account-video-settings/my-account-video-settings.component.ts | |||
@@ -29,14 +29,14 @@ export class MyAccountVideoSettingsComponent extends FormReactive implements OnI | |||
29 | ngOnInit () { | 29 | ngOnInit () { |
30 | this.buildForm({ | 30 | this.buildForm({ |
31 | nsfwPolicy: null, | 31 | nsfwPolicy: null, |
32 | webTorrentPolicy: null, | 32 | webTorrentEnabled: null, |
33 | autoPlayVideo: null | 33 | autoPlayVideo: null |
34 | }) | 34 | }) |
35 | 35 | ||
36 | this.userInformationLoaded.subscribe(() => { | 36 | this.userInformationLoaded.subscribe(() => { |
37 | this.form.patchValue({ | 37 | this.form.patchValue({ |
38 | nsfwPolicy: this.user.nsfwPolicy, | 38 | nsfwPolicy: this.user.nsfwPolicy, |
39 | webTorrentPolicy: this.user.webTorrentPolicy, | 39 | webTorrentEnabled: this.user.webTorrentEnabled, |
40 | autoPlayVideo: this.user.autoPlayVideo === true | 40 | autoPlayVideo: this.user.autoPlayVideo === true |
41 | }) | 41 | }) |
42 | }) | 42 | }) |
@@ -44,11 +44,11 @@ export class MyAccountVideoSettingsComponent extends FormReactive implements OnI | |||
44 | 44 | ||
45 | updateDetails () { | 45 | updateDetails () { |
46 | const nsfwPolicy = this.form.value['nsfwPolicy'] | 46 | const nsfwPolicy = this.form.value['nsfwPolicy'] |
47 | const webTorrentPolicy = this.form.value['webTorrentPolicy'] | 47 | const webTorrentEnabled = this.form.value['webTorrentEnabled'] |
48 | const autoPlayVideo = this.form.value['autoPlayVideo'] | 48 | const autoPlayVideo = this.form.value['autoPlayVideo'] |
49 | const details: UserUpdateMe = { | 49 | const details: UserUpdateMe = { |
50 | nsfwPolicy, | 50 | nsfwPolicy, |
51 | webTorrentPolicy, | 51 | webTorrentEnabled, |
52 | autoPlayVideo | 52 | autoPlayVideo |
53 | } | 53 | } |
54 | 54 | ||