Skip to content

Commit 5235c27

Browse files
committed
fixed url regex
1 parent ff9f669 commit 5235c27

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/de/kittybot/kittybot/objects/MusicPlayer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535

3636
public class MusicPlayer extends PlayerEventListenerAdapter{
3737

38-
public static final Pattern URL_PATTERN = Pattern.compile("^(https?://)?((www|m)\\.)?youtu(\\.be|be\\.com)/(playlist\\?list=([a-zA-Z0-9-_]+))?((watch\\?v=)?([a-zA-Z0-9-_]{11})(&list=([a-zA-Z0-9-_]+))?)?");
38+
public static final Pattern URL_PATTERN = Pattern.compile("^(https?|ftp|file)://[-a-zA-Z0-9+&@#/%?=~_|!:,.;]*[-a-zA-Z0-9+&@#/%=~_|]?");
3939
private static final Logger LOG = LoggerFactory.getLogger(MusicPlayer.class);
4040
private final LavalinkPlayer player;
4141
private final Queue<AudioTrack> queue;

0 commit comments

Comments
 (0)