Skip to content

Commit b9d43b4

Browse files
committed
chore: satisfy swiftformat and refresh native i18n inventory for pairing prompter changes
1 parent b63b50c commit b9d43b4

2 files changed

Lines changed: 15 additions & 15 deletions

File tree

apps/.i18n/native-source.json

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16083,63 +16083,63 @@
1608316083
},
1608416084
{
1608516085
"kind": "conditional-branch",
16086-
"line": 239,
16086+
"line": 263,
1608716087
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1608816088
"source": "New Mac wants to connect",
1608916089
"surface": "apple",
1609016090
"id": "native.apple.135336820846e999"
1609116091
},
1609216092
{
1609316093
"kind": "conditional-branch",
16094-
"line": 239,
16094+
"line": 263,
1609516095
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1609616096
"source": "New device wants to connect",
1609716097
"surface": "apple",
1609816098
"id": "native.apple.18c2594347b2c96e"
1609916099
},
1610016100
{
1610116101
"kind": "conditional-branch",
16102-
"line": 243,
16102+
"line": 267,
1610316103
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1610416104
"source": "this Mac app",
1610516105
"surface": "apple",
1610616106
"id": "native.apple.fbd59df61769188f"
1610716107
},
1610816108
{
1610916109
"kind": "conditional-branch",
16110-
"line": 243,
16110+
"line": 267,
1611116111
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1611216112
"source": "this device",
1611316113
"surface": "apple",
1611416114
"id": "native.apple.172ef5ed341ad73a"
1611516115
},
1611616116
{
1611716117
"kind": "conditional-branch",
16118-
"line": 248,
16118+
"line": 272,
1611916119
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1612016120
"source": "Approve Device",
1612116121
"surface": "apple",
1612216122
"id": "native.apple.809e76375508d27d"
1612316123
},
1612416124
{
1612516125
"kind": "conditional-branch",
16126-
"line": 248,
16126+
"line": 272,
1612716127
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1612816128
"source": "Approve Mac",
1612916129
"surface": "apple",
1613016130
"id": "native.apple.b5182817237683bc"
1613116131
},
1613216132
{
1613316133
"kind": "conditional-branch",
16134-
"line": 284,
16134+
"line": 308,
1613516135
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1613616136
"source": "New device",
1613716137
"surface": "apple",
1613816138
"id": "native.apple.40a3483823dbbd36"
1613916139
},
1614016140
{
1614116141
"kind": "conditional-branch",
16142-
"line": 284,
16142+
"line": 308,
1614316143
"path": "apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift",
1614416144
"source": "OpenClaw Mac app",
1614516145
"surface": "apple",
@@ -17779,15 +17779,15 @@
1777917779
},
1778017780
{
1778117781
"kind": "conditional-branch",
17782-
"line": 395,
17782+
"line": 399,
1778317783
"path": "apps/macos/Sources/OpenClaw/NodePairingApprovalPrompter.swift",
1778417784
"source": "Node pairing approved",
1778517785
"surface": "apple",
1778617786
"id": "native.apple.7eb0a88b8274ced8"
1778717787
},
1778817788
{
1778917789
"kind": "conditional-branch",
17790-
"line": 395,
17790+
"line": 399,
1779117791
"path": "apps/macos/Sources/OpenClaw/NodePairingApprovalPrompter.swift",
1779217792
"source": "Node pairing rejected",
1779317793
"surface": "apple",

apps/macos/Sources/OpenClaw/DevicePairingApprovalPrompter.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ final class DevicePairingApprovalPrompter {
146146

147147
switch response {
148148
case .alertFirstButtonReturn:
149-
if !(await self.approve(requestId: request.requestId)) {
149+
if await !(self.approve(requestId: request.requestId)) {
150150
// Stale request (expired or superseded on the gateway): re-sync the
151151
// queue with gateway truth so accumulated stale alerts collapse at once.
152152
await self.loadPendingRequestsFromGateway()
@@ -215,10 +215,10 @@ final class DevicePairingApprovalPrompter {
215215
}
216216
}
217217

218-
// The gateway keeps at most one live pending request per device, so a new
219-
// requestId for the same device supersedes anything still queued for it.
220-
// Without this, missed/dropped resolve pushes pile up as alerts whose
221-
// approval can no longer succeed. Returns nil when the request is already queued.
218+
/// The gateway keeps at most one live pending request per device, so a new
219+
/// requestId for the same device supersedes anything still queued for it.
220+
/// Without this, missed/dropped resolve pushes pile up as alerts whose
221+
/// approval can no longer succeed. Returns nil when the request is already queued.
222222
static func coalescedQueue(_ queue: [PendingRequest], adding req: PendingRequest) -> [PendingRequest]? {
223223
guard !queue.contains(where: { $0.requestId == req.requestId }) else { return nil }
224224
return queue.filter { $0.deviceId != req.deviceId } + [req]

0 commit comments

Comments
 (0)