Add a safety check for attempting to add unsupported URLs.

CQTexperiment
Christopher Snowhill 2018-09-23 16:44:44 -07:00
parent f01cfdb4fd
commit be2316163e
1 changed files with 4 additions and 0 deletions

View File

@ -393,6 +393,10 @@ NSMutableDictionary * dictionaryWithPropertiesOfObject(id obj, NSArray * filterL
int count = (int) [validURLs count];
if (xmlData) count += [[xmlData objectForKey:@"entries"] count];
// no valid URLs, or they use an unsupported URL scheme
if (!count)
return [NSArray array];
int i = 0;
NSMutableArray *entries = [NSMutableArray arrayWithCapacity:count];
for (NSURL *url in validURLs)