From 10c90a01f20dc7183bf06b70b21944b6a56597aa Mon Sep 17 00:00:00 2001 From: Isaac Grynsztein Date: Sun, 9 Feb 2020 23:35:01 -0500 Subject: [PATCH] linted files --- src/app/file-card/file-card.component.ts | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/src/app/file-card/file-card.component.ts b/src/app/file-card/file-card.component.ts index ac573a1..ce18ca6 100644 --- a/src/app/file-card/file-card.component.ts +++ b/src/app/file-card/file-card.component.ts @@ -11,11 +11,11 @@ import {EventEmitter} from '@angular/core'; }) export class FileCardComponent implements OnInit { - @Input() title:string; - @Input() length:string; - @Input() name:string; + @Input() title: string; + @Input() length: string; + @Input() name: string; @Input() thumbnailURL: string; - @Input() isAudio: boolean = true; + @Input() isAudio = true; @Output() removeFile: EventEmitter = new EventEmitter(); constructor(private postsService: PostsService, public snackBar: MatSnackBar, public appComponent: AppComponent) { } @@ -23,17 +23,13 @@ export class FileCardComponent implements OnInit { ngOnInit() { } - deleteFile() - { + deleteFile() { this.postsService.deleteFile(this.name, this.isAudio).subscribe(result => { - if (result == true) - { - this.openSnackBar("Delete success!", "OK."); + if (result === true) { + this.openSnackBar('Delete success!', 'OK.'); this.removeFile.emit(this.name); - } - else - { - this.openSnackBar("Delete failed!", "OK."); + } else { + this.openSnackBar('Delete failed!', 'OK.'); } }); }