Skip to content

Commit

Permalink
Remove redundant variable
Browse files Browse the repository at this point in the history
  • Loading branch information
gestrich committed Apr 28, 2024
1 parent 3252710 commit c167b1e
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,7 @@ class TimelineProvider: AppIntentTimelineProvider {
func getEntry(composer: ServiceComposer, configuration: ConfigurationAppIntent) async -> SimpleEntry {
return await withCheckedContinuation { continuation in
Task {

var looper: Looper
if let configurationLooper = try composer.accountServiceManager.getLoopers().first(where: {$0.id == configuration.looperID}) {
looper = configurationLooper
} else {
guard let looper = try composer.accountServiceManager.getLoopers().first(where: {$0.id == configuration.looperID}) else {
continuation.resume(returning: SimpleEntry(looper: nil, currentGlucoseSample: nil, lastGlucoseChange: nil, date: Date(), entryIndex: 0, isLastEntry: true, glucoseDisplayUnits: composer.settings.glucoseDisplayUnits))
return
}
Expand Down

0 comments on commit c167b1e

Please sign in to comment.