Added back the host.toString() method to support text-file logs

This commit is contained in:
Paulin Jorys 2017-07-11 13:25:27 +02:00
parent 4108d696e4
commit 1c0a575ccc

View File

@ -157,7 +157,7 @@ function beginBackgroundPollingOfHost(host) {
} }
function stopBackgroundPollingOfHost(host) { function stopBackgroundPollingOfHost(host) {
console.log('%c[Moonlight GUI, backgroundPolling]', 'color: green;', 'Stopping background polling of host ' + host.serverUid + '\n', host); console.log('%c[Moonlight GUI, backgroundPolling]', 'color: green;', 'Stopping background polling of host ' + host.serverUid + '\n', host, host.toString()); //Logging both object (for console) and toString-ed object (for text logs)
window.clearInterval(activePolls[host.serverUid]); window.clearInterval(activePolls[host.serverUid]);
delete activePolls[host.serverUid]; delete activePolls[host.serverUid];
} }
@ -407,7 +407,7 @@ function showApps(host) {
console.log('%c[Moonlight GUI, showApps]', 'color: green;', 'Moved into showApps, but `host` did not initialize properly! Failing.'); console.log('%c[Moonlight GUI, showApps]', 'color: green;', 'Moved into showApps, but `host` did not initialize properly! Failing.');
return; return;
} }
console.log('%c[Moonlight GUI, showApps]', 'color: green;', 'Current host object:', host); console.log('%c[Moonlight GUI, showApps]', 'color: green;', 'Current host object:', host, host.toString()); //Logging both object (for console) and toString-ed object (for text logs)
$('#quitCurrentApp').show(); $('#quitCurrentApp').show();
$("#gameList .game-container").remove(); $("#gameList .game-container").remove();