Prevents a crash due to nil NSError pointer