Fixed voting validation issue

This commit is contained in:
Brian Buller 2017-07-09 20:19:15 -05:00
parent cd42e7ab91
commit a10bfd175e

View File

@ -268,9 +268,11 @@ function getRanked() {
function gameTableToArray(tbl) { function gameTableToArray(tbl) {
var ret = []; var ret = [];
var trs = snack.wrap('#'+tbl+'-table>tbody>tr') var trs = snack.wrap('#'+tbl+'-table>tbody>tr')
if(trs[0].length > 0) { if(trs.length > 0) {
trs.each(function(ele, idx) { trs.each(function(ele, idx) {
if(ele.dataset != null && ele.dataset.teamid != null) {
ret = ret.concat(getTeamObj(ele.dataset.teamid)); ret = ret.concat(getTeamObj(ele.dataset.teamid));
}
}); });
} }
return ret; return ret;