From 003b5992344418bab9b49cf18a5d300c54bcef2f Mon Sep 17 00:00:00 2001 From: Julian Oes Date: Tue, 4 Jun 2024 14:35:37 +1200 Subject: [PATCH] ftp: split list_directory response This way we get a clear list of files and folders instead of an odd list with F or D prefixes. --- protos/ftp/ftp.proto | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/protos/ftp/ftp.proto b/protos/ftp/ftp.proto index 2dd0296d..0f68e5f3 100644 --- a/protos/ftp/ftp.proto +++ b/protos/ftp/ftp.proto @@ -77,9 +77,15 @@ message UploadResponse { message ListDirectoryRequest { string remote_dir = 1; // The remote directory to list the contents for. } + +message ListDirectoryData { + repeated string dirs = 1; // The found directories. + repeated string files = 2; // The found files. +} + message ListDirectoryResponse { FtpResult ftp_result = 1; - repeated string paths = 2; // The found directory contents. + ListDirectoryData data = 2; // The found directories and files. } message CreateDirectoryRequest {