]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/+signup/+register/register-step-channel.component.ts
Fix viewers for lives
[github/Chocobozzz/PeerTube.git] / client / src / app / +signup / +register / register-step-channel.component.ts
index 8a01208405c87333a04c2d35d7f119853cdd9345..d965a786550697e5a4bd54f53b2ecda715805fe9 100644 (file)
@@ -3,7 +3,8 @@ import { pairwise } from 'rxjs/operators'
 import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'
 import { FormGroup } from '@angular/forms'
 import { UserService } from '@app/core'
-import { FormReactive, FormValidatorService, VideoChannelValidatorsService } from '@app/shared/shared-forms'
+import { VIDEO_CHANNEL_DISPLAY_NAME_VALIDATOR, VIDEO_CHANNEL_NAME_VALIDATOR } from '@app/shared/form-validators/video-channel-validators'
+import { FormReactive, FormValidatorService } from '@app/shared/shared-forms'
 
 @Component({
   selector: 'my-register-step-channel',
@@ -16,8 +17,7 @@ export class RegisterStepChannelComponent extends FormReactive implements OnInit
 
   constructor (
     protected formValidatorService: FormValidatorService,
-    private userService: UserService,
-    private videoChannelValidatorsService: VideoChannelValidatorsService
+    private userService: UserService
   ) {
     super()
   }
@@ -28,8 +28,8 @@ export class RegisterStepChannelComponent extends FormReactive implements OnInit
 
   ngOnInit () {
     this.buildForm({
-      displayName: this.videoChannelValidatorsService.VIDEO_CHANNEL_DISPLAY_NAME,
-      name: this.videoChannelValidatorsService.VIDEO_CHANNEL_NAME
+      displayName: VIDEO_CHANNEL_DISPLAY_NAME_VALIDATOR,
+      name: VIDEO_CHANNEL_NAME_VALIDATOR
     })
 
     setTimeout(() => this.formBuilt.emit(this.form))