public static void next() {
        try {
            if(currentPlayback != null && nextTrack != null) {
                server.onTrackChange();
                setCurrentTrack(nextTrack);
                play();
            }
        } catch (MediaException e) {
            System.out.println("Invalid media type.");
        }
    }