aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/modal
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/modal')
-rw-r--r--client/src/app/modal/account-setup-warning-modal.component.ts3
-rw-r--r--client/src/app/modal/admin-welcome-modal.component.ts3
-rw-r--r--client/src/app/modal/custom-modal.component.ts5
-rw-r--r--client/src/app/modal/instance-config-warning-modal.component.ts3
4 files changed, 9 insertions, 5 deletions
diff --git a/client/src/app/modal/account-setup-warning-modal.component.ts b/client/src/app/modal/account-setup-warning-modal.component.ts
index c4cbf92b6..b999a3407 100644
--- a/client/src/app/modal/account-setup-warning-modal.component.ts
+++ b/client/src/app/modal/account-setup-warning-modal.component.ts
@@ -1,6 +1,7 @@
1import { Component, ElementRef, ViewChild } from '@angular/core' 1import { Component, ElementRef, ViewChild } from '@angular/core'
2import { Notifier, ServerService, User, UserService } from '@app/core' 2import { Notifier, ServerService, User, UserService } from '@app/core'
3import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap' 3import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap'
4import { logger } from '@root-helpers/logger'
4import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage' 5import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage'
5 6
6@Component({ 7@Component({
@@ -71,7 +72,7 @@ export class AccountSetupWarningModalComponent {
71 72
72 this.userService.updateMyProfile({ noAccountSetupWarningModal: true }) 73 this.userService.updateMyProfile({ noAccountSetupWarningModal: true })
73 .subscribe({ 74 .subscribe({
74 next: () => console.log('We will not open the account setup modal again.'), 75 next: () => logger.info('We will not open the account setup modal again.'),
75 76
76 error: err => this.notifier.error(err.message) 77 error: err => this.notifier.error(err.message)
77 }) 78 })
diff --git a/client/src/app/modal/admin-welcome-modal.component.ts b/client/src/app/modal/admin-welcome-modal.component.ts
index 3679f0847..7a9b89d3d 100644
--- a/client/src/app/modal/admin-welcome-modal.component.ts
+++ b/client/src/app/modal/admin-welcome-modal.component.ts
@@ -1,6 +1,7 @@
1import { Component, ElementRef, ViewChild } from '@angular/core' 1import { Component, ElementRef, ViewChild } from '@angular/core'
2import { Notifier, User, UserService } from '@app/core' 2import { Notifier, User, UserService } from '@app/core'
3import { NgbModal } from '@ng-bootstrap/ng-bootstrap' 3import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
4import { logger } from '@root-helpers/logger'
4import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage' 5import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage'
5 6
6@Component({ 7@Component({
@@ -42,7 +43,7 @@ export class AdminWelcomeModalComponent {
42 43
43 this.userService.updateMyProfile({ noWelcomeModal: true }) 44 this.userService.updateMyProfile({ noWelcomeModal: true })
44 .subscribe({ 45 .subscribe({
45 next: () => console.log('We will not open the welcome modal again.'), 46 next: () => logger.info('We will not open the welcome modal again.'),
46 47
47 error: err => this.notifier.error(err.message) 48 error: err => this.notifier.error(err.message)
48 }) 49 })
diff --git a/client/src/app/modal/custom-modal.component.ts b/client/src/app/modal/custom-modal.component.ts
index 559230e04..49343ae71 100644
--- a/client/src/app/modal/custom-modal.component.ts
+++ b/client/src/app/modal/custom-modal.component.ts
@@ -1,5 +1,6 @@
1import { Component, ElementRef, ViewChild, Input } from '@angular/core' 1import { Component, ElementRef, Input, ViewChild } from '@angular/core'
2import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap' 2import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap'
3import { logger } from '@root-helpers/logger'
3 4
4@Component({ 5@Component({
5 selector: 'my-custom-modal', 6 selector: 'my-custom-modal',
@@ -29,7 +30,7 @@ export class CustomModalComponent {
29 confirm?: { value: string, action?: () => void } 30 confirm?: { value: string, action?: () => void }
30 }) { 31 }) {
31 if (this.modalRef instanceof NgbModalRef && this.modalService.hasOpenModals()) { 32 if (this.modalRef instanceof NgbModalRef && this.modalService.hasOpenModals()) {
32 console.error('Cannot open another custom modal, one is already opened.') 33 logger.error('Cannot open another custom modal, one is already opened.')
33 return 34 return
34 } 35 }
35 36
diff --git a/client/src/app/modal/instance-config-warning-modal.component.ts b/client/src/app/modal/instance-config-warning-modal.component.ts
index 300738a41..23c2c777e 100644
--- a/client/src/app/modal/instance-config-warning-modal.component.ts
+++ b/client/src/app/modal/instance-config-warning-modal.component.ts
@@ -2,6 +2,7 @@ import { Location } from '@angular/common'
2import { Component, ElementRef, ViewChild } from '@angular/core' 2import { Component, ElementRef, ViewChild } from '@angular/core'
3import { Notifier, User, UserService } from '@app/core' 3import { Notifier, User, UserService } from '@app/core'
4import { NgbModal } from '@ng-bootstrap/ng-bootstrap' 4import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
5import { logger } from '@root-helpers/logger'
5import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage' 6import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage'
6import { About, ServerConfig } from '@shared/models/server' 7import { About, ServerConfig } from '@shared/models/server'
7 8
@@ -64,7 +65,7 @@ export class InstanceConfigWarningModalComponent {
64 65
65 this.userService.updateMyProfile({ noInstanceConfigWarningModal: true }) 66 this.userService.updateMyProfile({ noInstanceConfigWarningModal: true })
66 .subscribe({ 67 .subscribe({
67 next: () => console.log('We will not open the instance config warning modal again.'), 68 next: () => logger.info('We will not open the instance config warning modal again.'),
68 69
69 error: err => this.notifier.error(err.message) 70 error: err => this.notifier.error(err.message)
70 }) 71 })