Add nil-check for the input string when initializing the parser
This commit is contained in:
@@ -78,7 +78,7 @@
|
||||
_stackOfOpenElements = [HTMLStackOfOpenElements new];
|
||||
_listOfActiveFormattingElements = [HTMLListOfActiveFormattingElements new];
|
||||
|
||||
_tokenizer = [[HTMLTokenizer alloc] initWithString:string];
|
||||
_tokenizer = [[HTMLTokenizer alloc] initWithString:string ?: @""];
|
||||
_tokenizer.parser = self;
|
||||
|
||||
_pendingTableCharacterTokens = [[HTMLCharacterToken alloc] initWithString:@""];
|
||||
|
||||
Reference in New Issue
Block a user