From 60e7a4013c26306605b48bcae4de96af9710f8a8 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Sun, 15 Aug 2021 18:23:42 +0200 Subject: [PATCH] fix detection for the java program, it may not work if one java process is already running --- start.bat | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/start.bat b/start.bat index af17426..05dbf0b 100644 --- a/start.bat +++ b/start.bat @@ -7,8 +7,8 @@ if exist Lavalink.jar ( call download.bat ) -tasklist /fi "ImageName eq Lavalink.jar" /fo csv 2> NUL | find /I "Lavalink.jar" > NUL -if "%ERRORLEVEL%" == "0" ( +tasklist /FI "ImageName eq java.exe" 2> NUL | find /i "java.exe" | find /i "Console" > NUL +if %ERRORLEVEL% == 0 ( echo "Lavaling already started." ) else ( echo "Starting Lavalink server ..."