Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fixed still hidden charts after invalid data
The graphs gets hidden when invalid data ('N/A') gets delivered from the server-side. When valid data gets delivered without reloading page again, graphs are still hidden. Fixed.

Signed-off-by: Patrik Kernstock <[email protected]>
  • Loading branch information
patschi committed Jun 9, 2017
commit b1f1db1fece6e73361229cfd9eccb1c4c4c9641f
6 changes: 6 additions & 0 deletions js/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@
$('#cpuFooterInfo').text(t('serverinfo', 'CPU info not available'));
$('#cpuloadcanvas').addClass('hidden');
return;

} else if ($("#cpuloadcanvas").hasClass('hidden')) {
$("#cpuloadcanvas").removeClass('hidden');
}

var cpu1 = cpuload[0],
Expand Down Expand Up @@ -84,6 +87,9 @@
$('#memFooterInfo').text(t('serverinfo', 'Memory info not available'));
$('#memorycanvas').addClass('hidden');
return;

} else if ($("#memorycanvas").hasClass('hidden')) {
$("#memorycanvas").removeClass('hidden');
}

var memTotalBytes = memTotal * 1024,
Expand Down