From 4973666a133dc03e70c7935832e8ccff8b8c5baa Mon Sep 17 00:00:00 2001 From: Simon Hanna Date: Wed, 22 Aug 2018 21:29:20 +0200 Subject: [PATCH] Cleanup --- src/app/app.component.ts | 19 ++++++++----------- src/app/openlp.service.ts | 2 +- src/app/service.component.ts | 2 +- 3 files changed, 10 insertions(+), 13 deletions(-) diff --git a/src/app/app.component.ts b/src/app/app.component.ts index bfbec90..8e62ef6 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -14,41 +14,38 @@ export class AppComponent { constructor(private openlpService: OpenLPService) { openlpService.stateChanged$.subscribe(item => this.state = item); - openlpService.getServiceItems().subscribe(result => { - console.log(result); - }); } nextItem() { - this.openlpService.nextItem().subscribe(res => console.log(res)); + this.openlpService.nextItem().subscribe(); } previousItem() { - this.openlpService.previousItem().subscribe(res => console.log(res)); + this.openlpService.previousItem().subscribe(); } nextSlide() { - this.openlpService.nextSlide().subscribe(res => console.log(res)); + this.openlpService.nextSlide().subscribe(); } previousSlide() { - this.openlpService.previousSlide().subscribe(res => console.log(res)); + this.openlpService.previousSlide().subscribe(); } blankDisplay() { - this.openlpService.blankDisplay().subscribe(res => console.log(res)); + this.openlpService.blankDisplay().subscribe(); } themeDisplay() { - this.openlpService.themeDisplay().subscribe(res => console.log(res)); + this.openlpService.themeDisplay().subscribe(); } desktopDisplay() { - this.openlpService.desktopDisplay().subscribe(res => console.log(res)); + this.openlpService.desktopDisplay().subscribe(); } showDisplay() { - this.openlpService.showDisplay().subscribe(res => console.log(res)); + this.openlpService.showDisplay().subscribe(); } } diff --git a/src/app/openlp.service.ts b/src/app/openlp.service.ts index f793f44..4250671 100644 --- a/src/app/openlp.service.ts +++ b/src/app/openlp.service.ts @@ -7,7 +7,7 @@ import { Slide } from './slide'; import { ServiceItem } from './service_item'; import { Observable } from 'rxjs'; import { map, take } from 'rxjs/operators'; -import { SlideOuterResponse, PluginDescription } from './responses'; +import { PluginDescription } from './responses'; let deserialize = (json, cls) => { var inst = new cls(); diff --git a/src/app/service.component.ts b/src/app/service.component.ts index b8bfa2e..a0aa197 100644 --- a/src/app/service.component.ts +++ b/src/app/service.component.ts @@ -19,7 +19,7 @@ providers: [OpenLPService] }) export class OpenLPServiceComponent implements OnInit { - items = null; + items = []; ngOnInit() { this.getServiceItems(); }