Skip to content

Commit c0144d5

Browse files
committed
- NSURL+OCVaultTools: handle case where OCVault.storageRootURL returns nil (f.ex. if no File Provider is available or included), fixing a crash on macOS when dragging a file into the app.
1 parent b8f372e commit c0144d5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

ownCloudAppFramework/Foundation Extensions/NSURL+OCVaultTools.m

+5
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,11 @@ - (BOOL)isLocatedWithinVaultStorage
3131
NSString *vaultRootPath = OCVault.storageRootURL.path;
3232
NSString *path = self.path;
3333

34+
if (vaultRootPath == nil)
35+
{
36+
return (NO);
37+
}
38+
3439
if (![vaultRootPath hasSuffix:@"/"])
3540
{
3641
vaultRootPath = [vaultRootPath stringByAppendingString:@"/"];

0 commit comments

Comments
 (0)