Skip to content

Commit

Permalink
Merge pull request #1083 from Oyveloper/master
Browse files Browse the repository at this point in the history
Set peripheral delegate when restoring state
  • Loading branch information
marcosinigaglia authored Oct 12, 2023
2 parents d6d3d98 + fb6ba75 commit 6e6940f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions ios/BleManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -1148,6 +1148,7 @@ -(void)centralManager:(CBCentralManager *)central willRestoreState:(NSDictionary
NSMutableArray *data = [NSMutableArray new];
for (CBPeripheral *peripheral in peripherals) {
[data addObject:[peripheral asDictionary]];
peripheral.delegate = self;
}

[self sendEventWithName:@"BleManagerCentralManagerWillRestoreState" body:@{@"peripherals": data}];
Expand Down

0 comments on commit 6e6940f

Please sign in to comment.