From dc1151a5ffaa2aa9d05168086832e7337373f937 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kornel=20Lesin=CC=81ski?= Date: Tue, 3 Jan 2017 16:13:15 +0000 Subject: [PATCH] Null warning --- TestApplication/SUTestApplicationDelegate.m | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/TestApplication/SUTestApplicationDelegate.m b/TestApplication/SUTestApplicationDelegate.m index 10929a4b..39812ce0 100644 --- a/TestApplication/SUTestApplicationDelegate.m +++ b/TestApplication/SUTestApplicationDelegate.m @@ -155,8 +155,10 @@ static NSString * const UPDATED_VERSION = @"2.0"; // Copy our appcast over to the server directory NSURL *appcastDestinationURL = [[serverDirectoryURL URLByAppendingPathComponent:appcastName] URLByAppendingPathExtension:appcastExtension]; + NSURL *appcastPath = [mainBundle URLForResource:appcastName withExtension:appcastExtension]; + assert(appcastPath); NSError *copyAppcastError = nil; - if (![fileManager copyItemAtURL:[mainBundle URLForResource:appcastName withExtension:appcastExtension] toURL:appcastDestinationURL error:©AppcastError]) { + if (![fileManager copyItemAtURL:appcastPath toURL:appcastDestinationURL error:©AppcastError]) { NSLog(@"Failed to copy appcast into cache directory with error %@", copyAppcastError); assert(NO); }