add optional parameter sto allow chat code to specify it's uncertain if a name is right

needed for #393 (but not actually a fix)
This commit is contained in:
Jon Atkins 2013-06-24 18:09:53 +01:00
parent 8a71f7fdf0
commit 751c2068fe

View File

@ -80,7 +80,9 @@ window.resolvePlayerNames = function() {
} }
window.setPlayerName = function(guid, nick) { window.setPlayerName = function(guid, nick, uncertain) {
if(uncertain && guid in localStorage) return;
if($.trim(('' + nick)).slice(0, 5) === '{"L":' && !window.alertFor37WasShown) { if($.trim(('' + nick)).slice(0, 5) === '{"L":' && !window.alertFor37WasShown) {
window.alertFor37WasShown = true; window.alertFor37WasShown = true;
alert('You have run into bug #37. Please help me solve it!\nCopy and paste this text and post it here:\nhttps://github.com/breunigs/ingress-intel-total-conversion/issues/37\nIf copy & pasting doesnt work, make a screenshot instead.\n\n\n' + window.debug.printStackTrace() + '\n\n\n' + JSON.stringify(nick)); alert('You have run into bug #37. Please help me solve it!\nCopy and paste this text and post it here:\nhttps://github.com/breunigs/ingress-intel-total-conversion/issues/37\nIf copy & pasting doesnt work, make a screenshot instead.\n\n\n' + window.debug.printStackTrace() + '\n\n\n' + JSON.stringify(nick));