Updates realtime-advanced

This commit is contained in:
Manu Mtz-Almeida
2015-05-14 17:01:02 +02:00
parent 58ceb244e5
commit 286d775de6
4 changed files with 19 additions and 23 deletions

View File

@ -47,17 +47,15 @@ function StartEpoch(timestamp) {
]
});
if($('#messagesChart').length ) {
window.messagesChart = $('#messagesChart').epoch({
type: 'time.area',
axes: ['bottom', 'left'],
height: 250,
data: [
{values: defaultData},
{values: defaultData}
]
});
}
window.messagesChart = $('#messagesChart').epoch({
type: 'time.area',
axes: ['bottom', 'left'],
height: 250,
data: [
{values: defaultData},
{values: defaultData}
]
});
}
function StartSSE(roomid) {
@ -75,9 +73,7 @@ function stats(e) {
heapChart.push(data.heap)
mallocsChart.push(data.mallocs)
goroutinesChart.push(data.goroutines)
if (typeof messagesChart !== 'undefined') {
messagesChart.push(data.messages)
}
messagesChart.push(data.messages)
}
function parseJSONStats(e) {