aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/menu.component.ts
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2016-08-21 11:27:24 +0200
committerChocobozzz <florian.bigard@gmail.com>2016-08-21 11:27:24 +0200
commitbeacf6993c93f93bf5ea86665827154eb291d1fd (patch)
tree5aa8b69bbf4891c8d34798b052236f0ebfb94963 /client/src/app/menu.component.ts
parent9aa46b0c7bade696a477626ad7590ffdd281e03c (diff)
downloadPeerTube-beacf6993c93f93bf5ea86665827154eb291d1fd.tar.gz
PeerTube-beacf6993c93f93bf5ea86665827154eb291d1fd.tar.zst
PeerTube-beacf6993c93f93bf5ea86665827154eb291d1fd.zip
Client: simplify simple menu/admin menu displaying logic
Diffstat (limited to 'client/src/app/menu.component.ts')
-rw-r--r--client/src/app/menu.component.ts7
1 files changed, 1 insertions, 6 deletions
diff --git a/client/src/app/menu.component.ts b/client/src/app/menu.component.ts
index 594cd996e..6b08301df 100644
--- a/client/src/app/menu.component.ts
+++ b/client/src/app/menu.component.ts
@@ -1,4 +1,4 @@
1import { Component, EventEmitter, OnInit, Output } from '@angular/core'; 1import { Component, OnInit } from '@angular/core';
2import { Router, ROUTER_DIRECTIVES } from '@angular/router'; 2import { Router, ROUTER_DIRECTIVES } from '@angular/router';
3 3
4import { AuthService, AuthStatus } from './shared'; 4import { AuthService, AuthStatus } from './shared';
@@ -9,7 +9,6 @@ import { AuthService, AuthStatus } from './shared';
9 directives: [ ROUTER_DIRECTIVES ] 9 directives: [ ROUTER_DIRECTIVES ]
10}) 10})
11export class MenuComponent implements OnInit { 11export class MenuComponent implements OnInit {
12 @Output() enteredInAdmin = new EventEmitter<boolean>();
13 isLoggedIn: boolean; 12 isLoggedIn: boolean;
14 13
15 constructor ( 14 constructor (
@@ -35,10 +34,6 @@ export class MenuComponent implements OnInit {
35 ); 34 );
36 } 35 }
37 36
38 enterInAdmin() {
39 this.enteredInAdmin.emit(true);
40 }
41
42 isUserAdmin() { 37 isUserAdmin() {
43 return this.authService.isAdmin(); 38 return this.authService.isAdmin();
44 } 39 }