Skip to content

Commit

Permalink
Resolve some todos
Browse files Browse the repository at this point in the history
  • Loading branch information
Supereg committed Nov 17, 2024
1 parent 0ab64d1 commit 2328379
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
5 changes: 3 additions & 2 deletions Sources/SpeziDevices/PairedDevices.swift
Original file line number Diff line number Diff line change
Expand Up @@ -262,12 +262,14 @@ public final class PairedDevices { // TODO: update docs!

/// Update the user-chosen name of a paired device.
///
/// - Note: If your Accessory is managed through the AccessorySetupKit, please make sure to rename the accessory through AccessorySetupKit such that the
/// name is visible in the Settings App and other applications as well.
///
/// - Parameters:
/// - deviceInfo: The paired device information for which to update the name.
/// - name: The new name.
@MainActor
public func updateName(for deviceInfo: PairedDeviceInfo, name: String) {
// TODO: document that askit rename works differently + accessory retrieval API!
logger.debug("Updated name for paired device \(deviceInfo.id): \(name) %")
deviceInfo.name = name
}
Expand Down Expand Up @@ -825,7 +827,6 @@ extension PairedDevices {
logger.debug("Received accessory change: \(String(describing: event))")

switch event {
// TODO: all of this could race, we need "locks" for each accessory (removal and addition)?
case .available:
if let accessories = accessorySetup?.accessories {
Task {
Expand Down
1 change: 0 additions & 1 deletion Sources/SpeziDevicesUI/Devices/DevicesGrid.swift
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ public struct DevicesGrid: View {
ProgressView()
}
}
// TODO: this is a problem when this view is presented inside a navigation destination?
.navigationDestination(item: $detailedDeviceInfo) { deviceInfo in
DeviceDetailsView(deviceInfo)
}
Expand Down

0 comments on commit 2328379

Please sign in to comment.