epl-fixtures
Advanced tools
Comparing version 1.0.1 to 1.1.0
{ | ||
"name": "epl-fixtures", | ||
"version": "1.0.1", | ||
"version": "1.1.0", | ||
"description": "Fixtures for Premier League clubs", | ||
@@ -49,4 +49,5 @@ "main": "src/fixtures.js", | ||
"cheerio": "^0.20.0", | ||
"got": "^6.3.0" | ||
"got": "^6.3.0", | ||
"moment": "^2.12.0" | ||
} | ||
} |
@@ -5,2 +5,3 @@ 'use strict'; | ||
const trim = require('./trim'); | ||
const moment = require('moment'); | ||
@@ -47,4 +48,5 @@ module.exports = function (html, callback) { | ||
const location = trim($(this).find('td.location').text()); | ||
const userLocaleTime = moment(time + ' UTC +01:00', 'HH:mm ZZ').format('HH:mm'); | ||
matches.push({time, clubs, location, date, competition}); | ||
matches.push({time, clubs, location, date, competition, userLocaleTime}); | ||
} | ||
@@ -51,0 +53,0 @@ }); |
@@ -54,3 +54,3 @@ 'use strict'; | ||
it('contains time, clubs, location, date and competition', function () { | ||
it('contains time, clubs, location, date and competition, userLocaleTime', function () { | ||
expect(allClubsFixtures[0]).to.have.property('time'); | ||
@@ -61,2 +61,3 @@ expect(allClubsFixtures[0]).to.have.property('clubs'); | ||
expect(allClubsFixtures[0]).to.have.property('competition'); | ||
expect(allClubsFixtures[0]).to.have.property('userLocaleTime'); | ||
}); | ||
@@ -63,0 +64,0 @@ }); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
10668
242
3
+ Addedmoment@^2.12.0
+ Addedmoment@2.30.1(transitive)