Skip to content

Commit

Permalink
1.6.1dev: follow-up to [17878], fix unable to save //not-configured//…
Browse files Browse the repository at this point in the history
… in syntax highlighting of user preferences (refs #13864)

git-svn-id: http://trac.edgewall.org/intertrac/log:/branches/1.6-stable@17881 af82e41b-90c4-0310-8c96-b1721e28e2e2
  • Loading branch information
jomae committed Feb 6, 2025
1 parent ed4c150 commit 74073a6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion trac/mimeview/pygments.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,9 @@ def style_defs(style):
if default_style not in styles:
default_style = 'trac'
selection = req.session.get('pygments_style')
if selection not in styles:
if not selection:
selection = ''
elif selection not in styles:
selection = default_style
output = self._generate('html', self.EXAMPLE)
add_script_data(req, default_style=default_style, selection=selection)
Expand Down

0 comments on commit 74073a6

Please sign in to comment.