Skip to content

Commit f9ff34e

Browse files
committed
rebased with small changes
1 parent f62839f commit f9ff34e

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

client/commands/v2/pysa_server.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
_read_lsp_request,
3030
try_initialize,
3131
_log_lsp_event,
32+
_publish_diagnostics,
3233
InitializationExit,
3334
InitializationSuccess,
3435
InitializationFailure,
@@ -139,9 +140,7 @@ async def show_model_errors_to_client(
139140
self, diagnostics: Dict[Path, List[lsp.Diagnostic]]
140141
) -> None:
141142
for path, diagnostic in diagnostics.items():
142-
await _publish_diagnostics(self.output_channel, path, [])
143-
if diagnostic is not None:
144-
await _publish_diagnostics(self.output_channel, path, diagnostic)
143+
await _publish_diagnostics(self.output_channel, path, diagnostic or [])
145144

146145
async def wait_for_exit(self) -> int:
147146
while True:

0 commit comments

Comments
 (0)