From cee44618a876c782b4a0be209cb5be7875fdfd3e Mon Sep 17 00:00:00 2001 From: Vivien Nicolas Date: Tue, 1 Mar 2022 17:13:28 +0100 Subject: [PATCH] [Darwin] Invert the logic for getting the path to use for the KVS as it was inverted by mistake in #15586 --- src/platform/Darwin/KeyValueStoreManagerImpl.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/platform/Darwin/KeyValueStoreManagerImpl.mm b/src/platform/Darwin/KeyValueStoreManagerImpl.mm index 289357dac0f40e..ee8c789f9b6a28 100644 --- a/src/platform/Darwin/KeyValueStoreManagerImpl.mm +++ b/src/platform/Darwin/KeyValueStoreManagerImpl.mm @@ -156,7 +156,7 @@ - (instancetype)initWithContext:(nonnull NSManagedObjectContext *)context key:(n ReturnErrorCodeIf(filepath == nil, CHIP_ERROR_INVALID_ARGUMENT); // relative paths are relative to Documents folder - if ([filepath hasPrefix:@"/"]) { + if (![filepath hasPrefix:@"/"]) { NSURL * documentsDirectory = [NSFileManager.defaultManager URLForDirectory:NSDocumentDirectory inDomain:NSUserDomainMask appropriateForURL:nil