Merge pull request #336 from wb9688/fix-time-parsing

Fix YouTube video duration parsing
This commit is contained in:
Tobias Groza 2020-05-30 10:36:46 +02:00 committed by GitHub
commit bda83fe6a5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -142,9 +142,9 @@ public class YoutubeParsingHelper {
default:
throw new ParsingException("Error duration string with unknown format: " + input);
}
return (((Long.parseLong(Utils.removeNonDigitCharacters(days)) * 24)
return ((((Long.parseLong(Utils.removeNonDigitCharacters(days)) * 24)
+ Long.parseLong(Utils.removeNonDigitCharacters(hours)) * 60)
+ Long.parseLong(Utils.removeNonDigitCharacters(minutes)) * 60)
+ Long.parseLong(Utils.removeNonDigitCharacters(minutes))) * 60)
+ Long.parseLong(Utils.removeNonDigitCharacters(seconds));
}