Remove newline characters from API file logs

This commit is contained in:
luukas 2022-05-25 18:41:16 +03:00
parent 3956d9c699
commit 2e51fa9629
No known key found for this signature in database
GPG Key ID: CC4915E8D71FC044

View File

@ -45,6 +45,9 @@ class ApiServersServerLogsHandler(BaseApiHandler):
self.helper.get_os_understandable_path(server_data["log_path"]),
log_lines,
)
# Remove newline characters from the end of the lines
raw_lines = [line.rstrip("\r\n") for line in raw_lines]
else:
raw_lines = ServerOutBuf.lines.get(server_id, [])