flea-killer
Advanced tools
Comparing version 0.1.3 to 0.1.4
@@ -53,3 +53,3 @@ // League scraper | ||
// Teams in the league | ||
$('.league-standings tr.first th .tt-content').each(function() { | ||
$('.league-standings tr:nth-child(2) th .tt-content').each(function() { | ||
league.stats.push($(this).text()); | ||
@@ -79,4 +79,4 @@ }); | ||
team.stats[stat] = { | ||
points: parseFloat(row.find('td:nth-child(' + (3 * index + 4) + ')').text()), | ||
value: parseFloat(row.find('td:nth-child(' + (3 * index + 5) + ')').text().replace(/,/g, '')) | ||
points: parseFloat(row.find('td:nth-child(' + (3 * index + 4) + ')' + ' .text-muted').text()), | ||
value: parseFloat(row.find('td:nth-child(' + (3 * index + 4) + ')' + ' .nowrap').text().replace(/,/g, '')) | ||
} | ||
@@ -83,0 +83,0 @@ }); |
{ | ||
"name": "flea-killer", | ||
"version": "0.1.3", | ||
"version": "0.1.4", | ||
"description": "Fleaflicker Baseball API", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -64,4 +64,4 @@ var expect = require('chai').expect, | ||
// Cant test individual stats that well | ||
// expect(league.teams[0].stats.HR.points).to.equal(7); | ||
// expect(league.teams[0].stats.HR.value).to.equal(30); | ||
// expect(league.teams[0].stats.HR.points).to.equal(10); | ||
// expect(league.teams[0].stats.HR.value).to.equal(99); | ||
done(); | ||
@@ -68,0 +68,0 @@ }); |
23083