simont77 / fakegato-history

Module to emulate Elgato Eve history
MIT License
167 stars 15 forks source link

disableTimer bug #44

Closed ebaauw closed 6 years ago

ebaauw commented 6 years ago

Specifying {disableTimer: true} in the options to the FakeGatoHistory constructor has a side-effect, causing Eve no longer to display the history. Now the entry is passed by reference to _addEntry(). When using the timer, the entry is re-constructed using the backlog, effectively passing the entry by value to _addEntry(). When the plugin calls addEntry with new values for the same object (e.g. add.Entry(this.entry), all history entries change, because they refer to the same object.