1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2026-04-20 21:54:58 -04:00

Improve scene mapping updating

Closes #8452
This commit is contained in:
Mark McDowall
2026-03-08 11:31:41 -07:00
parent fbb70519b1
commit 526ef5428d
6 changed files with 66 additions and 10 deletions
@@ -7,7 +7,7 @@ namespace NzbDrone.Core.DataAugmentation.Scene
public interface ISceneMappingRepository : IBasicRepository<SceneMapping>
{
List<SceneMapping> FindByTvdbid(int tvdbId);
void Clear(string type);
List<SceneMapping> GetAllByType(string type);
}
public class SceneMappingRepository : BasicRepository<SceneMapping>, ISceneMappingRepository
@@ -22,9 +22,9 @@ namespace NzbDrone.Core.DataAugmentation.Scene
return Query(x => x.TvdbId == tvdbId);
}
public void Clear(string type)
public List<SceneMapping> GetAllByType(string type)
{
Delete(s => s.Type == type);
return Query(x => x.Type == type);
}
}
}