do not do code for local user move twice

This commit is contained in:
yamanq 2015-07-08 01:06:09 -04:00
parent d291132a24
commit 4f58af98aa

View File

@ -68,14 +68,8 @@ function serverTransfer(coordinate,team,turn,username) {
})
.then(
function success(data) {
//*******************************
// TODO Use moves given by server
//*******************************
console.log(data);
for (var user in data) {
if (data.hasOwnProperty(user)) {
if (data.hasOwnProperty(user) && (user != username)) {
console.log(data[user][turn]);
var theMove = data[user][turn];
tableUpdate(theMove[1], theMove[2]);