Revert last push

This commit is contained in:
Andrew 2021-11-19 21:56:09 -05:00
parent bd3da474f5
commit 79190e15f5
2 changed files with 3 additions and 3 deletions

View File

@ -215,8 +215,7 @@ class AjaxHandler(BaseHandler):
server_id = self.get_argument('id', None)
if file_path.contains('/') or file_path('\\'):
server_info = self.controller.servers.get_server_data_by_id(server_id)
file_path = os.path.abspath(os.path.join(server_info["backup_path"], file_path))
file_path = file_path.replace('/', "\\")
console.warning("delete {} for server {}".format(file_path, server_id))

View File

@ -204,7 +204,8 @@
callback: function (result) {
console.log(result);
if (result == true) {
del_backup(file_to_del, {{ data['server_stats']['server_id']['server_id'] }} );
var full_path = '{{ data['server_stats']['server_id']['backup_path'] }}' + '/' + file_to_del;
del_backup(full_path, {{ data['server_stats']['server_id']['server_id'] }} );
}
}
});