-
Notifications
You must be signed in to change notification settings - Fork 375
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
4.0 release, memory leaks fixes #158
Conversation
Source/BluetoothManager.swift
Outdated
return self.centralManager.retrieveConnectedPeripherals(withServices: serviceUUIDs) | ||
let observable = Observable<[Peripheral]>.deferred { [weak self] in | ||
guard let strongSelf = self else { throw BluetoothError.destroyed } | ||
return strongSelf.centralManager.retrieveConnectedPeripherals(withServices: serviceUUIDs) | ||
.map { (peripheralTable: [RxPeripheralType]) -> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
strongSelf will be locked during retrieveConnectedPeripherals
??
Source/BluetoothManager.swift
Outdated
.map { (peripheralTable: [RxPeripheralType]) -> | ||
[Peripheral] in peripheralTable.map { | ||
Peripheral(manager: self, peripheral: $0) | ||
Peripheral(manager: strongSelf, peripheral: $0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same story here
RxBluetoothKit.podspec
Outdated
@@ -20,5 +20,5 @@ Pod::Spec.new do |s| | |||
|
|||
s.source_files = 'Source/*.swift' | |||
s.frameworks = 'CoreBluetooth' | |||
s.dependency 'RxSwift', '4.0.0-rc.0' | |||
s.dependency 'RxSwift', '4.0.0' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like you'd much rather have a dependency like s.dependency 'RxSwift', '~> 4.0'
, instead of a hard dependency on 4.0.0
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's right, thank you!
Fixes #156 , final preparation for official 4.0 release