diff --git a/index.php b/index.php index 96e2cedd..0549b8d9 100755 --- a/index.php +++ b/index.php @@ -342,7 +342,7 @@ else if(isset($_GET['do'])) chdir("mods"); foreach(glob("*") as $modname) { // server_announce = true - if(isset($_POST[$modname])) { + if(isset($_POST[$modname]) && !is_dir("mtm_db/worlds/$userid/worlds/world/worldmods/" . $_POST[$modname] . "/")) { echo "Copying $modname..."; chdir(".."); file_put_contents("mtm_db/events/$userid", "cp -a mods/$modname mtm_db/worlds/$userid/worlds/world/worldmods/$modname");