diff --git a/src/components/views/DownloadModModal.vue b/src/components/views/DownloadModModal.vue index 24383e638..572ff8cf0 100644 --- a/src/components/views/DownloadModModal.vue +++ b/src/components/views/DownloadModModal.vue @@ -114,6 +114,14 @@ import { Progress } from '../all'; import Game from '../../model/game/Game'; import ConflictManagementProvider from '../../providers/generic/installing/ConflictManagementProvider'; +interface DownloadProgress { + assignId: number; + initialMods: string[]; + modName: string; + progress: number; + failed: boolean; +} + let assignId = 0; @Component({ @@ -124,12 +132,12 @@ let assignId = 0; export default class DownloadModModal extends Vue { versionNumbers: string[] = []; - downloadObject: any | null = null; + downloadObject: DownloadProgress | null = null; downloadingMod: boolean = false; selectedVersion: string | null = null; currentVersion: string | null = null; - static allVersions: [number, any][] = []; + static allVersions: [number, DownloadProgress][] = []; get activeGame(): Game { return this.$store.state.activeGame; @@ -281,7 +289,7 @@ let assignId = 0; assignId: currentAssignId, failed: false, } - if (this.downloadObject.assignId === currentAssignId) { + if (this.downloadObject!.assignId === currentAssignId) { this.downloadObject = Object.assign({}, obj); } this.$set(DownloadModModal.allVersions, assignIndex, [currentAssignId, obj]); @@ -322,7 +330,7 @@ let assignId = 0; assignId: currentAssignId, failed: false, } - if (this.downloadObject.assignId === currentAssignId) { + if (this.downloadObject!.assignId === currentAssignId) { this.downloadObject = Object.assign({}, obj); } this.$set(DownloadModModal.allVersions, assignIndex, [currentAssignId, obj]);