mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-12-14 11:23:42 +02:00
Fixed duplicate id searches due to missing Equals on SceneSeasonMapping
This commit is contained in:
parent
c3e2f22adb
commit
efb18223fe
@ -11,5 +11,19 @@ public class SceneSeasonMapping
|
|||||||
public SearchMode SearchMode { get; set; }
|
public SearchMode SearchMode { get; set; }
|
||||||
public List<string> SceneTitles { get; set; }
|
public List<string> SceneTitles { get; set; }
|
||||||
public int SeasonNumber { get; set; }
|
public int SeasonNumber { get; set; }
|
||||||
|
|
||||||
|
public override int GetHashCode()
|
||||||
|
{
|
||||||
|
return SearchMode.GetHashCode() ^ SeasonNumber.GetHashCode();
|
||||||
|
}
|
||||||
|
|
||||||
|
public override bool Equals(object obj)
|
||||||
|
{
|
||||||
|
var other = obj as SceneSeasonMapping;
|
||||||
|
|
||||||
|
if (object.ReferenceEquals(other, null)) return false;
|
||||||
|
|
||||||
|
return SeasonNumber == other.SeasonNumber && SearchMode == other.SearchMode;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user