diff --git a/src/main/java/me/srrapero720/watermedia/api/config/support/CustomDirectoryProvider.java b/src/main/java/me/srrapero720/watermedia/api/config/support/CustomDirectoryProvider.java new file mode 100644 index 00000000..f44e61e1 --- /dev/null +++ b/src/main/java/me/srrapero720/watermedia/api/config/support/CustomDirectoryProvider.java @@ -0,0 +1,21 @@ +package me.srrapero720.watermedia.api.config.support; + +import me.srrapero720.watermedia.WaterMedia; +import uk.co.caprica.vlcj.discovery.provider.DiscoveryDirectoryProvider; + +public class CustomDirectoryProvider implements DiscoveryDirectoryProvider { + @Override + public int priority() { + return 5; + } + + @Override + public boolean supported() { + return true; + } + + @Override + public String[] directories() { + return new String[] {WaterMedia.getLoader().tempDir().resolve("videolan").toAbsolutePath().toString()}; + } +} diff --git a/src/main/resources/META-INF/services/uk.co.caprica.vlcj.discovery.provider.DiscoveryDirectoryProvider b/src/main/resources/META-INF/services/uk.co.caprica.vlcj.discovery.provider.DiscoveryDirectoryProvider new file mode 100644 index 00000000..6ee90850 --- /dev/null +++ b/src/main/resources/META-INF/services/uk.co.caprica.vlcj.discovery.provider.DiscoveryDirectoryProvider @@ -0,0 +1 @@ +me.srrapero720.watermedia.api.config.support.CustomDirectoryProvider \ No newline at end of file