Only show client properties if there's something to show.
This commit is contained in:
parent
b0dca51901
commit
a2dee73c73
|
|
@ -347,3 +347,11 @@ function fmt_sort(display, sort) {
|
|||
}
|
||||
return '<a class="sort" sort="' + sort + '">' + prefix + display + '</a>';
|
||||
}
|
||||
|
||||
function properties_size(obj) {
|
||||
var count = 0;
|
||||
for (k in obj) {
|
||||
if (obj.hasOwnProperty(k)) count++;
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
|
@ -131,12 +131,14 @@
|
|||
</div>
|
||||
<% } %>
|
||||
|
||||
<% if (properties_size(connection.client_properties) > 0) { %>
|
||||
<div class="section-hidden">
|
||||
<h2>Client Library</h2>
|
||||
<div class="hider">
|
||||
<%= fmt_table_long(connection.client_properties) %>
|
||||
</div>
|
||||
</div>
|
||||
<% } %>
|
||||
|
||||
<div class="section-hidden">
|
||||
<h2>Close This Connection</h2>
|
||||
|
|
|
|||
Loading…
Reference in New Issue