aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+signup/+register/register-step-user.component.ts
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/+signup/+register/register-step-user.component.ts')
-rw-r--r--client/src/app/+signup/+register/register-step-user.component.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/client/src/app/+signup/+register/register-step-user.component.ts b/client/src/app/+signup/+register/register-step-user.component.ts
index 716cd8c78..92ddfca2e 100644
--- a/client/src/app/+signup/+register/register-step-user.component.ts
+++ b/client/src/app/+signup/+register/register-step-user.component.ts
@@ -2,7 +2,6 @@ import { concat, of } from 'rxjs'
2import { pairwise } from 'rxjs/operators' 2import { pairwise } from 'rxjs/operators'
3import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core' 3import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'
4import { FormGroup } from '@angular/forms' 4import { FormGroup } from '@angular/forms'
5import { UserService } from '@app/core'
6import { 5import {
7 USER_DISPLAY_NAME_REQUIRED_VALIDATOR, 6 USER_DISPLAY_NAME_REQUIRED_VALIDATOR,
8 USER_EMAIL_VALIDATOR, 7 USER_EMAIL_VALIDATOR,
@@ -10,6 +9,7 @@ import {
10 USER_USERNAME_VALIDATOR 9 USER_USERNAME_VALIDATOR
11} from '@app/shared/form-validators/user-validators' 10} from '@app/shared/form-validators/user-validators'
12import { FormReactive, FormValidatorService } from '@app/shared/shared-forms' 11import { FormReactive, FormValidatorService } from '@app/shared/shared-forms'
12import { UserSignupService } from '@app/shared/shared-users'
13 13
14@Component({ 14@Component({
15 selector: 'my-register-step-user', 15 selector: 'my-register-step-user',
@@ -23,7 +23,7 @@ export class RegisterStepUserComponent extends FormReactive implements OnInit {
23 23
24 constructor ( 24 constructor (
25 protected formValidatorService: FormValidatorService, 25 protected formValidatorService: FormValidatorService,
26 private userService: UserService 26 private userSignupService: UserSignupService
27 ) { 27 ) {
28 super() 28 super()
29 } 29 }
@@ -52,7 +52,7 @@ export class RegisterStepUserComponent extends FormReactive implements OnInit {
52 private onDisplayNameChange (oldDisplayName: string, newDisplayName: string) { 52 private onDisplayNameChange (oldDisplayName: string, newDisplayName: string) {
53 const username = this.form.value['username'] || '' 53 const username = this.form.value['username'] || ''
54 54
55 const newUsername = this.userService.getNewUsername(oldDisplayName, newDisplayName, username) 55 const newUsername = this.userSignupService.getNewUsername(oldDisplayName, newDisplayName, username)
56 this.form.patchValue({ username: newUsername }) 56 this.form.patchValue({ username: newUsername })
57 } 57 }
58} 58}