From c73d11b8013b1a153d98c25151d3d8b3a892ed23 Mon Sep 17 00:00:00 2001 From: Aaron Louie Date: Fri, 31 Jan 2020 11:36:14 -0500 Subject: [PATCH] Renames variables for clarity --- src/app/file-list/file-list.component.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/app/file-list/file-list.component.ts b/src/app/file-list/file-list.component.ts index 2c69eb4..54e9433 100644 --- a/src/app/file-list/file-list.component.ts +++ b/src/app/file-list/file-list.component.ts @@ -47,12 +47,12 @@ export class FileListComponent implements OnInit { }); } - makePrimary(fm: FileMeta) { - if (fm.type === FileType.BPMN) { + makePrimary(fmPrimary: FileMeta) { + if (fmPrimary.type === FileType.BPMN) { let numUpdated = 0; - this.fileMetas.forEach(f => { - f.primary = (fm.id === f.id); - this.api.updateFileMeta(this.workflowSpec.id, f).subscribe(() => { + this.fileMetas.forEach(fm => { + fm.primary = (fmPrimary.id === fm.id); + this.api.updateFileMeta(this.workflowSpec.id, fm).subscribe(() => { numUpdated++; // Reload all fileMetas when all have been updated.