Better release of memory.

This commit is contained in:
macmade
2023-02-06 19:21:33 +01:00
parent 6abe1aa8ac
commit eb261cec9d

View File

@@ -70,8 +70,11 @@ public class Sensors: NSObject
RunLoop.current.run( until: Date( timeIntervalSinceNow: 5 ) )
}
timer.invalidate()
let completion = self.completion
self.completion = nil
self.data = []
completion?()
}