Merge pull request '[Fix] Handle invalid data-episode-count
' (#1) from fix/episode-range-parse into main
Reviewed-on: #1
This commit is contained in:
@ -100,6 +100,9 @@ public class KodikHtmlParserService {
|
||||
|
||||
private static int parseIntSafely(String value) {
|
||||
try {
|
||||
if (value.contains("~")) {
|
||||
return Integer.parseInt(value.split("~")[1]);
|
||||
}
|
||||
return Integer.parseInt(value);
|
||||
} catch (NumberFormatException e) {
|
||||
log.error(String.format("invalid number format %s", value), e);
|
||||
|
Reference in New Issue
Block a user