]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/+my-account/my-account-settings/my-account-notification-preferences/my-account-notification-preferences.component.ts
Use HTML config when possible
[github/Chocobozzz/PeerTube.git] / client / src / app / +my-account / my-account-settings / my-account-notification-preferences / my-account-notification-preferences.component.ts
index c7e17303812825e4086fca013ca24baec3dff476..b94e6ad824d77ec37b05ca2c67646816fdf2907c 100644 (file)
@@ -60,10 +60,8 @@ export class MyAccountNotificationPreferencesComponent implements OnInit {
   }
 
   ngOnInit () {
-    this.serverService.getConfig()
-        .subscribe(config => {
-          this.emailEnabled = config.email.enabled
-        })
+    const serverConfig = this.serverService.getHTMLConfig()
+    this.emailEnabled = serverConfig.email.enabled
 
     this.userInformationLoaded.subscribe(() => this.loadNotificationSettings())
   }