Skip to content

Commit

Permalink
Sphinx: using method from Tags module
Browse files Browse the repository at this point in the history
Getting rid of deprecation warning for next major Sphinx version.
  • Loading branch information
gusthoff committed Oct 26, 2024
1 parent 423f256 commit adcae3a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions frontend/sphinx/widget_extension.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,8 +260,7 @@ def run(self) -> List[Node]:
widget.parseContent(self.content)

# Attemping to detect HTML or Latex output by checking for 'html' in tags
if ('builder_html' in self.state.state_machine.document.settings.env.app.tags.tags
and self.state.state_machine.document.settings.env.app.tags.tags['builder_html']):
if (self.state.state_machine.document.settings.env.app.tags.eval_condition('builder_html')):

jinja_env = Environment(
loader=PackageLoader('widget'),
Expand Down

0 comments on commit adcae3a

Please sign in to comment.