Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
jwortmann committed Oct 31, 2023
1 parent 58ca97e commit c38f287
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions plugin/documents.py
Original file line number Diff line number Diff line change
Expand Up @@ -484,8 +484,10 @@ def _on_hover_gutter_async(self, point: int) -> None:
diagnostics_with_config = [] # type: List[Tuple[ClientConfig, Diagnostic]]
max_severity_level = min(userprefs().show_diagnostics_severity_level, DiagnosticSeverity.Information)
for sb, diagnostics in self.diagnostics_intersecting_async(self.view.line(point))[0]:
diagnostics_with_config.extend((sb.session.config, diagnostic) for diagnostic in diagnostics
if diagnostic_severity(diagnostic) <= max_severity_level)
diagnostics_with_config.extend(
(sb.session.config, diagnostic) for diagnostic in diagnostics
if diagnostic_severity(diagnostic) <= max_severity_level
)
if diagnostics_with_config:
diagnostics_with_config.sort(key=lambda d: diagnostic_severity(d[1]))
content += '<div class="diagnostics">'
Expand Down

0 comments on commit c38f287

Please sign in to comment.