From ddc08539daac8749d477d31c1c75fa8b880bef4f Mon Sep 17 00:00:00 2001 From: Andrew Lauppe Date: Mon, 26 Jan 2026 07:41:08 -0500 Subject: [PATCH] fix: use if expressions instead of ternary for conditionalAssignment rule --- apps/macos/Sources/Clawdbot/AppState.swift | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/apps/macos/Sources/Clawdbot/AppState.swift b/apps/macos/Sources/Clawdbot/AppState.swift index b6096ab06..bf881b8be 100644 --- a/apps/macos/Sources/Clawdbot/AppState.swift +++ b/apps/macos/Sources/Clawdbot/AppState.swift @@ -419,9 +419,17 @@ final class AppState { let user = (trimmedUser?.isEmpty ?? true) ? nil : trimmedUser let port = parsed.port let assembled = if let user { - port == 22 ? "\(user)@\(host)" : "\(user)@\(host):\(port)" + if port == 22 { + "\(user)@\(host)" + } else { + "\(user)@\(host):\(port)" + } } else { - port == 22 ? host : "\(host):\(port)" + if port == 22 { + host + } else { + "\(host):\(port)" + } } if assembled != self.remoteTarget { self.remoteTarget = assembled