Skip to content

Commit

Permalink
Merge pull request #16 from Shepless/develop
Browse files Browse the repository at this point in the history
Added AirDay, AirTime, Runtime and Status to TV Shows
  • Loading branch information
enyo committed Apr 19, 2014
2 parents 96488dc + d05fc9a commit 5daa04b
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 5 deletions.
6 changes: 5 additions & 1 deletion lib/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@
"node": ">=0.6.x <0.9"
},
"dependencies": {
"xml2js": "0.x",
"xml2js": "0.2.x",
"underscore": "1.x",
"adm-zip": "0.4.x"
},
"devDependencies": {
"mocha": "1.x",
"coffee-script": "1.x",
"coffee-script": "1.6.x",
"should": "0.x"
}
}
3 changes: 2 additions & 1 deletion src/index.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,8 @@ class TVDB
done undefined, formattedResult

formatTvShow: (tvShow) ->
keyMapping = IMDB_ID: 'imdbId', zap2it_id: 'zap2itId', banner: 'banner', Overview: 'overview'
keyMapping = IMDB_ID: 'imdbId', zap2it_id: 'zap2itId', banner: 'banner', Overview: 'overview', Airs_DayOfWeek: 'airDay', Airs_Time: 'airTime',
Runtime: 'runtime', Status: 'status'
formattedTvShow =
id: tvShow.id,
genre: tvShow.Genre,
Expand Down
2 changes: 1 addition & 1 deletion test/tvdb-api.test.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ describe "tvdb", ->
dataFileUri = __dirname + "/data/series.single.xml"
tvdb.getInfoTvShow "id", (err, tvShow) ->
tvShow.id.should.equal "70327"
Object.getOwnPropertyNames(tvShow).length.should.equal 9
Object.getOwnPropertyNames(tvShow).length.should.equal 11
done()

describe "getInfoEpisode()", ->
Expand Down

0 comments on commit 5daa04b

Please sign in to comment.