Skip to content

Commit f3a9fe9

Browse files
Remove unused checkIsRunning on MTRDeviceController. (project-chip#36337)
Only MTRDeviceController_Concrete needs to do checkIsRunning at this point, and it implements that itself.
1 parent ddd8e0b commit f3a9fe9

File tree

1 file changed

+0
-22
lines changed

1 file changed

+0
-22
lines changed

src/darwin/Framework/CHIP/MTRDeviceController.mm

-22
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,6 @@
5757

5858
#import <os/lock.h>
5959

60-
// TODO: These strings and their consumers in this file should probably go away,
61-
// since none of them really apply to all controllers.
62-
static NSString * const kErrorNotRunning = @"Controller is not running. Call startup first.";
6360
static NSString * const kErrorSpake2pVerifierGenerationFailed = @"PASE verifier generation failed";
6461
static NSString * const kErrorSpake2pVerifierSerializationFailed = @"PASE verifier serialization failed";
6562

@@ -473,25 +470,6 @@ + (BOOL)checkForError:(CHIP_ERROR)errorCode logMsg:(NSString *)logMsg error:(NSE
473470
return YES;
474471
}
475472

476-
- (BOOL)checkIsRunning
477-
{
478-
return [self checkIsRunning:nil];
479-
}
480-
481-
- (BOOL)checkIsRunning:(NSError * __autoreleasing *)error
482-
{
483-
if ([self isRunning]) {
484-
return YES;
485-
}
486-
487-
MTR_LOG_ERROR("%@: %@ Error: %s", NSStringFromClass(self.class), self, [kErrorNotRunning UTF8String]);
488-
if (error) {
489-
*error = [MTRError errorForCHIPErrorCode:CHIP_ERROR_INCORRECT_STATE];
490-
}
491-
492-
return NO;
493-
}
494-
495473
- (void)asyncDispatchToMatterQueue:(dispatch_block_t)block errorHandler:(nullable MTRDeviceErrorHandler)errorHandler
496474
{
497475
// TODO: Figure out how to get callsites to have an MTRDeviceController_Concrete.

0 commit comments

Comments
 (0)