mirror of
https://github.com/TeamNewPipe/NewPipeExtractor
synced 2025-10-06 00:23:15 +02:00
[SoundCloud] SoundCloudStreamExtractor.getTimeStamp return 0 if no timestamp in url
This commit is contained in:
@@ -121,7 +121,8 @@ public class SoundcloudStreamExtractor extends StreamExtractor {
|
||||
|
||||
@Override
|
||||
public long getTimeStamp() throws ParsingException {
|
||||
return getTimestampSeconds("(#t=\\d{0,3}h?\\d{0,3}m?\\d{1,3}s?)");
|
||||
final var timestamp = getTimestampSeconds("(#t=\\d{0,3}h?\\d{0,3}m?\\d{1,3}s?)");
|
||||
return timestamp == -2 ? 0 : timestamp;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -170,7 +171,7 @@ public class SoundcloudStreamExtractor extends StreamExtractor {
|
||||
|
||||
try {
|
||||
final JsonArray transcodings = track.getObject("media")
|
||||
.getArray("transcodings");
|
||||
.getArray("transcodings");
|
||||
if (!isNullOrEmpty(transcodings)) {
|
||||
// Get information about what stream formats are available
|
||||
extractAudioStreams(transcodings, audioStreams);
|
||||
|
Reference in New Issue
Block a user