diff options
author | proller <proller@github.com> | 2013-03-30 02:36:06 +0400 |
---|---|---|
committer | proller <proller@github.com> | 2013-03-30 02:36:06 +0400 |
commit | 177ca4f4d55368718eb295f1010ad5c81660af57 (patch) | |
tree | 75415532d8ecd6519aae54e1591b85f0bcd820e6 | |
parent | 16c11eb4a3bb46a388c645b7db738762e444cde8 (diff) | |
download | minetest-177ca4f4d55368718eb295f1010ad5c81660af57.tar.gz minetest-177ca4f4d55368718eb295f1010ad5c81660af57.tar.bz2 minetest-177ca4f4d55368718eb295f1010ad5c81660af57.zip |
Fix backward compatibility for server uptime in master server web page
-rw-r--r-- | util/master/list.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/util/master/list.js b/util/master/list.js index 18cbc4b68..990bb6ded 100644 --- a/util/master/list.js +++ b/util/master/list.js @@ -54,9 +54,8 @@ function success(r) { h += '</td>'; h += '<td class="mts_description">' + e(s.description) + '</td>'; h += '<td class="mts_flags">' + e(s.password ? 'Pwd ' : '') + (s.creative ? 'Cre ' : '') + (s.damage ? 'Dmg ' : '') + (s.pvp ? 'Pvp ' : '') + (s.dedicated ? 'Ded ' : '') + '</td>'; - if (!s.time || s.time < 0) s.time = 0; if (!s.start || s.start < 0) s.start = 0; - h += '<td class="mts_time">' + (s.uptime ? human_time(s.uptime, 1) : '') + '</td>'; + h += '<td class="mts_time">' + (s.uptime ? human_time(s.uptime, 1) : s.start ? human_time(s.start) : '') + '</td>'; h += '<td class="mts_ping">' + (s.ping ? parseFloat(s.ping).toFixed(3) * 1000 : '') + '</td>'; h += '</tr>'; } |