Commit 30b3be9ba5

30b3be9ba558d802adeb8fd2ef50b10442d462a6

parent: 9c41ef5269

Unsigned

cmc <hello@cleberg.net> · 2026-07-16 16:13 UTC

fix: move the S1186 empty-block comments inside the braces

Trailing // comments after {} left the block lexically empty, so
SonarCloud kept flagging stopLoading (and would have re-flagged the two
Cancel buttons). S1186 wants a *nested* comment; use /* ... */ inside.

Layout: unified · split

Hutch/Views/Patchsets/PatchsetDetailView.swift +1 −1
@@ -71,7 +71,7 @@ struct PatchsetDetailView: View {
7171 Task { await viewModel.updateStatus(to: status) }
7272 }
7373 }
74 Button("Cancel", role: .cancel) {} // dismisses the dialog; no action needed
74 Button("Cancel", role: .cancel) { /* dismisses the dialog; no action needed */ }
7575 }
7676 .alert(
7777 "Couldn't Update Patchset",
Hutch/Views/Tickets/TicketDetailView.swift +1 −1
@@ -204,7 +204,7 @@ struct TicketDetailView: View {
204204 }
205205 }
206206 }
207 Button("Cancel", role: .cancel) {} // dismisses the dialog; no action needed
207 Button("Cancel", role: .cancel) { /* dismisses the dialog; no action needed */ }
208208 } message: {
209209 Text("This permanently deletes the ticket and its comments. This cannot be undone.")
210210 }
HutchTests/APICacheTests.swift +1 −1
@@ -294,7 +294,7 @@ private final class CachedURLProtocol: URLProtocol, @unchecked Sendable {
294294 }
295295 }
296296
297 override func stopLoading() {} // required override; nothing to tear down
297 override func stopLoading() { /* required override; nothing to tear down */ }
298298
299299 static func reset(responses: [CachedURLProtocolResponse], responseDelay: TimeInterval = 0) {
300300 Self.responses = responses