Remove unused storage member from MTROperationalCredentialsDelegate. (#28378)
diff --git a/src/darwin/Framework/CHIP/MTRDeviceController.mm b/src/darwin/Framework/CHIP/MTRDeviceController.mm
index 59a4c33..8b34769 100644
--- a/src/darwin/Framework/CHIP/MTRDeviceController.mm
+++ b/src/darwin/Framework/CHIP/MTRDeviceController.mm
@@ -268,8 +268,8 @@
}
signingKeypair = &_signingKeypairBridge;
}
- errorCode = _operationalCredentialsDelegate->Init(_factory.storageDelegateBridge, signingKeypair, startupParams.ipk,
- startupParams.rootCertificate, startupParams.intermediateCertificate);
+ errorCode = _operationalCredentialsDelegate->Init(
+ signingKeypair, startupParams.ipk, startupParams.rootCertificate, startupParams.intermediateCertificate);
if ([self checkForStartError:errorCode logMsg:kErrorOperationalCredentialsInit]) {
return;
}
diff --git a/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.h b/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.h
index b3dfd24..63499f0 100644
--- a/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.h
+++ b/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.h
@@ -41,8 +41,7 @@
MTROperationalCredentialsDelegate(MTRDeviceController * deviceController);
~MTROperationalCredentialsDelegate() {}
- CHIP_ERROR Init(MTRPersistentStorageDelegateBridge * storage, ChipP256KeypairPtr nocSigner, NSData * ipk, NSData * rootCert,
- NSData * _Nullable icaCert);
+ CHIP_ERROR Init(ChipP256KeypairPtr nocSigner, NSData * ipk, NSData * rootCert, NSData * _Nullable icaCert);
CHIP_ERROR GenerateNOCChain(const chip::ByteSpan & csrElements, const chip::ByteSpan & csrNonce,
const chip::ByteSpan & attestationSignature, const chip::ByteSpan & attestationChallenge, const chip::ByteSpan & DAC,
@@ -137,8 +136,6 @@
chip::Crypto::IdentityProtectionKey mIPK;
- MTRPersistentStorageDelegateBridge * mStorage;
-
chip::NodeId mDeviceBeingPaired = chip::kUndefinedNodeId;
chip::NodeId mNextRequestedNodeId = 1;
diff --git a/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm b/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm
index 887fd20..7e5282e 100644
--- a/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm
+++ b/src/darwin/Framework/CHIP/MTROperationalCredentialsDelegate.mm
@@ -48,15 +48,13 @@
{
}
-CHIP_ERROR MTROperationalCredentialsDelegate::Init(MTRPersistentStorageDelegateBridge * storage, ChipP256KeypairPtr nocSigner,
- NSData * ipk, NSData * rootCert, NSData * _Nullable icaCert)
+CHIP_ERROR MTROperationalCredentialsDelegate::Init(
+ ChipP256KeypairPtr nocSigner, NSData * ipk, NSData * rootCert, NSData * _Nullable icaCert)
{
- if (storage == nil || ipk == nil || rootCert == nil) {
+ if (ipk == nil || rootCert == nil) {
return CHIP_ERROR_INVALID_ARGUMENT;
}
- mStorage = storage;
-
mIssuerKey = nocSigner;
if ([ipk length] != mIPK.Length()) {