diff --git a/source/net/filebot/web/HyperLink.java b/source/net/filebot/web/HyperLink.java index 0417df19..49721844 100644 --- a/source/net/filebot/web/HyperLink.java +++ b/source/net/filebot/web/HyperLink.java @@ -14,7 +14,7 @@ public class HyperLink extends SearchResult { } public HyperLink(String name, URL url) { - super(name); + super(name, new String[0]); this.url = url; } diff --git a/source/net/filebot/web/MultiEpisode.java b/source/net/filebot/web/MultiEpisode.java index 6fd1d4aa..3c87739f 100644 --- a/source/net/filebot/web/MultiEpisode.java +++ b/source/net/filebot/web/MultiEpisode.java @@ -8,11 +8,15 @@ import java.util.List; public class MultiEpisode extends Episode { - private Episode[] episodes; + protected Episode[] episodes; + + protected MultiEpisode() { + // used by serializer + } public MultiEpisode(Episode... episodes) { super(episodes[0]); - this.episodes = episodes; + this.episodes = episodes.clone(); } public List getEpisodes() { @@ -35,7 +39,7 @@ public class MultiEpisode extends Episode { @Override public MultiEpisode clone() { - return new MultiEpisode(episodes.clone()); + return new MultiEpisode(episodes); } @Override diff --git a/source/net/filebot/web/SearchResult.java b/source/net/filebot/web/SearchResult.java index ceb5428c..4d35414a 100644 --- a/source/net/filebot/web/SearchResult.java +++ b/source/net/filebot/web/SearchResult.java @@ -14,9 +14,9 @@ public abstract class SearchResult implements Serializable { // used by serializer } - public SearchResult(String name, String... aliasNames) { + public SearchResult(String name, String[] aliasNames) { this.name = name; - this.aliasNames = aliasNames; + this.aliasNames = aliasNames.clone(); } public String getName() { diff --git a/source/net/filebot/web/TVRageSearchResult.java b/source/net/filebot/web/TVRageSearchResult.java index 65b0dcfd..f431adef 100644 --- a/source/net/filebot/web/TVRageSearchResult.java +++ b/source/net/filebot/web/TVRageSearchResult.java @@ -10,7 +10,7 @@ public class TVRageSearchResult extends SearchResult { } public TVRageSearchResult(String name, int showId, String link) { - super(name); + super(name, new String[0]); this.showId = showId; this.link = link; }