Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Only override episode/season numbers if the file name has them

  • Loading branch information...
commit 2ae1f0b777809e4b7810a60f83deedbbe37def25 1 parent 5419971
@ScudLee ScudLee authored
Showing with 6 additions and 3 deletions.
  1. +6 −3 xbmc/video/VideoInfoScanner.cpp
View
9 xbmc/video/VideoInfoScanner.cpp
@@ -1351,9 +1351,12 @@ namespace VIDEO
if (result == CNfoFile::FULL_NFO)
{
m_nfoReader.GetDetails(*item.GetVideoInfoTag());
- // override with episode and season number
- item.GetVideoInfoTag()->m_iEpisode = file->iEpisode;
- item.GetVideoInfoTag()->m_iSeason = file->iSeason;
+ // override with episode and season number from file if available
+ if (file->iEpisode > -1)
+ {
+ item.GetVideoInfoTag()->m_iEpisode = file->iEpisode;
+ item.GetVideoInfoTag()->m_iSeason = file->iSeason;
+ }
if (AddVideo(&item, CONTENT_TVSHOWS, file->isFolder, true, &showInfo) < 0)
return INFO_ERROR;
continue;
Please sign in to comment.
Something went wrong with that request. Please try again.