Skip to content

Commit

Permalink
Address review comment
Browse files Browse the repository at this point in the history
  • Loading branch information
jtung-apple committed Sep 21, 2023
1 parent 68305da commit 66cb7a5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/darwin/Framework/CHIP/MTRDevice.mm
Original file line number Diff line number Diff line change
Expand Up @@ -441,9 +441,11 @@ - (void)_handleReportEnd
// For unit testing only
#ifdef DEBUG
id delegate = _weakDelegate.strongObject;
if (delegate && [delegate respondsToSelector:@selector(unitTestReportEndForDevice:)]) {
if (delegate) {
dispatch_async(_delegateQueue, ^{
[delegate unitTestReportEndForDevice:self];
if ([delegate respondsToSelector:@selector(unitTestReportEndForDevice:)]) {
[delegate unitTestReportEndForDevice:self];
}
});
}
#endif
Expand Down

0 comments on commit 66cb7a5

Please sign in to comment.