From c7d683ff53f9a28097be08d9a90f9dc8cf427eba Mon Sep 17 00:00:00 2001 From: dev-claw <53543762+dev-claw@users.noreply.github.com> Date: Thu, 30 Apr 2026 22:35:56 +0100 Subject: [PATCH] fixes #303 --- .../web/grpc/GrpcServerAppEndpointService.kt | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/vripper-web/src/main/kotlin/me/vripper/web/grpc/GrpcServerAppEndpointService.kt b/vripper-web/src/main/kotlin/me/vripper/web/grpc/GrpcServerAppEndpointService.kt index 8e94ead..88fb2dd 100644 --- a/vripper-web/src/main/kotlin/me/vripper/web/grpc/GrpcServerAppEndpointService.kt +++ b/vripper-web/src/main/kotlin/me/vripper/web/grpc/GrpcServerAppEndpointService.kt @@ -213,15 +213,13 @@ class GrpcServerAppEndpointService : EndpointServiceGrpcKt.EndpointServiceCorout enableClipboardMonitoring = request.systemSettings.enableClipboardMonitoring, clipboardPollingRate = request.systemSettings.clipboardPollingRate, maxEventLog = request.systemSettings.maxEventLog, - ), - hostSettings = request.hostSettingsMap.entries.associate { hostSettings -> + ), hostSettings = request.hostSettingsMap.entries.associate { hostSettings -> HostName.valueOf(hostSettings.key) to hostSettings.value.settingsMap.entries.associate { HostSettingKey.valueOf( it.key ) to it.value } - } - ) + }) ) return EndpointServiceOuterClass.EmptyResponse.getDefaultInstance() } @@ -293,11 +291,22 @@ class GrpcServerAppEndpointService : EndpointServiceGrpcKt.EndpointServiceCorout build() } + val hostSettings = settings.hostSettings.entries.associate { + val hostSettings = with(SettingsOuterClass.HostSettingsMap.newBuilder()) { + this.putAllSettings(it.value.entries.associate { setting -> + setting.key.name to setting.value + }) + build() + } + it.key.name to hostSettings + } + return with(SettingsOuterClass.Settings.newBuilder()) { this.connectionSettings = connectionSettings this.downloadSettings = downloadSettings this.viperSettings = viperSettings this.systemSettings = systemSettings + this.putAllHostSettings(hostSettings) build() } }