diff --git a/BGS/Objective.cs b/BGS/Objective.cs index aee1b17..9331a4d 100644 --- a/BGS/Objective.cs +++ b/BGS/Objective.cs @@ -1,9 +1,10 @@ using System.Collections.Generic; +using System; using System.Text; using Newtonsoft.Json; namespace NonaBGS.BGS { - public class Objective { + public class Objective : IComparable { private string system; private string station; private string faction; diff --git a/BGS/Report.cs b/BGS/Report.cs index f6c42fb..68888d6 100644 --- a/BGS/Report.cs +++ b/BGS/Report.cs @@ -21,7 +21,7 @@ namespace NonaBGS.BGS { } public bool AddObjective(Objective objective) { - var found = objectives.Find(x => x == objective); + var found = objectives.Find(x => x.CompareTo(objective) == 0); bool added = false; if (found == null) {