diff options
author | Chocobozzz <me@florianbigard.com> | 2018-12-19 16:04:34 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-12-19 17:26:52 +0100 |
commit | f8b2c1b4f509c037b9650cca2c5befd21f056df3 (patch) | |
tree | 89d278f9628d657e6aad1b1e15febaf8ff9fcfa9 /client/src/app/+verify-account/verify-account-email/verify-account-email.component.ts | |
parent | e0e665f0efa98f2701dd9f5529e99989680481ae (diff) | |
download | PeerTube-f8b2c1b4f509c037b9650cca2c5befd21f056df3.tar.gz PeerTube-f8b2c1b4f509c037b9650cca2c5befd21f056df3.tar.zst PeerTube-f8b2c1b4f509c037b9650cca2c5befd21f056df3.zip |
Refractor notification service
Shorter name and use primeng component
Diffstat (limited to 'client/src/app/+verify-account/verify-account-email/verify-account-email.component.ts')
-rw-r--r-- | client/src/app/+verify-account/verify-account-email/verify-account-email.component.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/client/src/app/+verify-account/verify-account-email/verify-account-email.component.ts b/client/src/app/+verify-account/verify-account-email/verify-account-email.component.ts index e4a5522c8..f9ecf664b 100644 --- a/client/src/app/+verify-account/verify-account-email/verify-account-email.component.ts +++ b/client/src/app/+verify-account/verify-account-email/verify-account-email.component.ts | |||
@@ -1,7 +1,7 @@ | |||
1 | import { Component, OnInit } from '@angular/core' | 1 | import { Component, OnInit } from '@angular/core' |
2 | import { ActivatedRoute, Router } from '@angular/router' | 2 | import { ActivatedRoute, Router } from '@angular/router' |
3 | import { I18n } from '@ngx-translate/i18n-polyfill' | 3 | import { I18n } from '@ngx-translate/i18n-polyfill' |
4 | import { NotificationsService } from 'angular2-notifications' | 4 | import { Notifier } from '@app/core' |
5 | import { UserService } from '@app/shared' | 5 | import { UserService } from '@app/shared' |
6 | 6 | ||
7 | @Component({ | 7 | @Component({ |
@@ -17,7 +17,7 @@ export class VerifyAccountEmailComponent implements OnInit { | |||
17 | 17 | ||
18 | constructor ( | 18 | constructor ( |
19 | private userService: UserService, | 19 | private userService: UserService, |
20 | private notificationsService: NotificationsService, | 20 | private notifier: Notifier, |
21 | private router: Router, | 21 | private router: Router, |
22 | private route: ActivatedRoute, | 22 | private route: ActivatedRoute, |
23 | private i18n: I18n | 23 | private i18n: I18n |
@@ -29,7 +29,7 @@ export class VerifyAccountEmailComponent implements OnInit { | |||
29 | this.verificationString = this.route.snapshot.queryParams['verificationString'] | 29 | this.verificationString = this.route.snapshot.queryParams['verificationString'] |
30 | 30 | ||
31 | if (!this.userId || !this.verificationString) { | 31 | if (!this.userId || !this.verificationString) { |
32 | this.notificationsService.error(this.i18n('Error'), this.i18n('Unable to find user id or verification string.')) | 32 | this.notifier.error(this.i18n('Unable to find user id or verification string.')) |
33 | } else { | 33 | } else { |
34 | this.verifyEmail() | 34 | this.verifyEmail() |
35 | } | 35 | } |
@@ -46,7 +46,7 @@ export class VerifyAccountEmailComponent implements OnInit { | |||
46 | }, | 46 | }, |
47 | 47 | ||
48 | err => { | 48 | err => { |
49 | this.notificationsService.error(this.i18n('Error'), err.message) | 49 | this.notifier.error(err.message) |
50 | } | 50 | } |
51 | ) | 51 | ) |
52 | } | 52 | } |