Skip to content

Commit

Permalink
Fix NicoNico Regex (#61)
Browse files Browse the repository at this point in the history
  • Loading branch information
a9lim authored Jan 1, 2024
1 parent 049a241 commit c363f95
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
* Audio source manager that implements finding NicoNico tracks based on URL.
*/
public class NicoAudioSourceManager implements AudioSourceManager, HttpConfigurable {
private static final String TRACK_URL_REGEX = "^(?:http://|https://|)(?:www\\.|)nicovideo\\.jp/watch/(sm[0-9]+)(?:\\?.*|)$";
private static final String TRACK_URL_REGEX = "^(?:http://|https://|)(?:www\\.|)nicovideo\\.jp/watch/(.{2}[0-9]+)(?:\\?.*|)$";

private static final Pattern trackUrlPattern = Pattern.compile(TRACK_URL_REGEX);

Expand Down

0 comments on commit c363f95

Please sign in to comment.