mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Working zip imports
This commit is contained in:
parent
b5420c083e
commit
504ffd57f6
@ -31,9 +31,11 @@ class FileHelpers:
|
||||
sub.unlink()
|
||||
except:
|
||||
logger.error(f"Unable to delete file {sub}")
|
||||
|
||||
# This removes the top-level folder:
|
||||
path.rmdir()
|
||||
try:
|
||||
# This removes the top-level folder:
|
||||
path.rmdir()
|
||||
except:
|
||||
logger.error("Unable to remove top level")
|
||||
return True
|
||||
|
||||
@staticmethod
|
||||
|
@ -106,5 +106,6 @@ class ImportHelpers:
|
||||
file.close()
|
||||
|
||||
server_users = PermissionsServers.get_server_user_list(new_id)
|
||||
ServersController.finish_import(new_id)
|
||||
for user in server_users:
|
||||
self.helper.websocket_helper.broadcast_user(user, "send_start_reload", {})
|
||||
|
@ -627,6 +627,7 @@ class Controller:
|
||||
port,
|
||||
server_type="minecraft-java",
|
||||
)
|
||||
ServersController.set_import(new_id)
|
||||
self.import_helper.import_java_zip_server(
|
||||
temp_dir, new_server_dir, port, new_id
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user