mirror of
https://github.com/mitb-archive/filebot
synced 2024-12-24 08:48:51 -05:00
* make sure we create unique objects for JSON serialization
This commit is contained in:
parent
7ae3fa8183
commit
762f9015af
@ -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;
|
||||
}
|
||||
|
||||
|
@ -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<Episode> getEpisodes() {
|
||||
@ -35,7 +39,7 @@ public class MultiEpisode extends Episode {
|
||||
|
||||
@Override
|
||||
public MultiEpisode clone() {
|
||||
return new MultiEpisode(episodes.clone());
|
||||
return new MultiEpisode(episodes);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -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() {
|
||||
|
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user