Skip to content

Commit

Permalink
add film even if they only have one (small) url
Browse files Browse the repository at this point in the history
  • Loading branch information
codingPF committed May 28, 2024
1 parent e0c5f12 commit e057760
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,18 @@ private Map<Resolution, FilmUrl> getOptimizedUrls(Map<Resolution, String> urls)
Resolution.HD, new FilmUrl(hdUrl.get(), crawler.determineFileSizeInKB(hdUrl.get())));
}
}

// FIXME
// old filmlist needs normal url - remove after decom
if (!result.containsKey(Resolution.NORMAL)) {
if (result.containsKey(Resolution.SMALL)) {
result.put(Resolution.NORMAL, result.get(Resolution.SMALL));
result.remove(Resolution.SMALL);
} else if (result.containsKey(Resolution.HD)) {
result.put(Resolution.NORMAL, result.get(Resolution.HD));
result.remove(Resolution.HD);
}
}
return result;
}
}

0 comments on commit e057760

Please sign in to comment.