File tree Expand file tree Collapse file tree 1 file changed +10
-11
lines changed Expand file tree Collapse file tree 1 file changed +10
-11
lines changed Original file line number Diff line number Diff line change @@ -119,17 +119,16 @@ def string_to_reactpy(
119119 ),
120120 )
121121 except etree .XMLSyntaxError as e :
122- if strict :
123- msg = (
124- "An error has occurred while parsing the HTML.\n \n "
125- "This HTML may be malformatted, or may not perfectly adhere to HTML5.\n "
126- "If you believe the exception above was due to something intentional, you "
127- "can disable the strict parameter on string_to_reactpy().\n "
128- "Otherwise, repair your broken HTML and try again."
129- )
130- raise HTMLParseError (msg ) from e
131- else :
132- return _etree_to_vdom (root_node , transforms , intercept_links )
122+ msg = (
123+ "An error has occurred while parsing the HTML.\n \n "
124+ "This HTML may be malformatted, or may not perfectly adhere to HTML5.\n "
125+ "If you believe the exception above was due to something intentional, you "
126+ "can disable the strict parameter on string_to_reactpy().\n "
127+ "Otherwise, repair your broken HTML and try again."
128+ )
129+ raise HTMLParseError (msg ) from e
130+
131+ return _etree_to_vdom (root_node , transforms , intercept_links )
133132
134133
135134class HTMLParseError (etree .LxmlSyntaxError ): # type: ignore[misc]
You can’t perform that action at this time.
0 commit comments