make Championship an instantiated class

This commit is contained in:
2023-12-02 17:10:54 +01:00
parent b98513e6f3
commit 0a14e69f82
3 changed files with 11 additions and 8 deletions
+2 -2
View File
@@ -8,7 +8,7 @@ export default class UI {
static updateFrequency = 500 // in ms
constructor(rootObject) {
this.next = null
this.next = new Championship()
this.rootObject = rootObject
this.savedParanoiaOffset = localStorage.getItem('paranoiaOffset') || 1
this.#setParanoiaOffset(this.savedParanoiaOffset)
@@ -42,7 +42,7 @@ export default class UI {
Day.update()
this.next = Championship.next // TODO: make "next" a standard format
this.next = Championship.next
if (Championship.nextChanged) {
this.#updateChampionshipDetails()