Do not store that many data points
This commit is contained in:
parent
917aeace49
commit
8193860bd9
@ -70,7 +70,7 @@ $(document).ready(function(){
|
|||||||
success: function(data) {
|
success: function(data) {
|
||||||
console.log(storedData.length);
|
console.log(storedData.length);
|
||||||
// Start dropping out elements
|
// Start dropping out elements
|
||||||
if (storedData.length > 60) { storedData.shift(); }
|
if (storedData.length > 20) { storedData.shift(); }
|
||||||
storedData[storedData.length] = [new Date().getTime(), data.getuserhashrate.hashrate];
|
storedData[storedData.length] = [new Date().getTime(), data.getuserhashrate.hashrate];
|
||||||
$.jqplot('hashrategraph', [storedData], jqPlotOptions).replot();
|
$.jqplot('hashrategraph', [storedData], jqPlotOptions).replot();
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user