Skip to content

Commit 3d52f2a

Browse files
committed
Fix bug where error results would accumulate
1 parent 7f23db3 commit 3d52f2a

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

sqlit/ui/mixins/query.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -309,12 +309,7 @@ def _display_non_query_result(self: AppProtocol, affected: int, elapsed_ms: floa
309309

310310
def _display_query_error(self: AppProtocol, error_message: str) -> None:
311311
"""Display query error (called on main thread)."""
312-
self._last_result_columns = ["Error"]
313-
self._last_result_rows = [(error_message,)]
314-
self._last_result_row_count = 1
315-
316-
# escape_markup is handled in _replace_results_table
317-
self._replace_results_table(["Error"], [(error_message,)])
312+
# notify(severity="error") handles displaying the error in results via _show_error_in_results
318313
self.notify(f"Query error: {error_message}", severity="error")
319314

320315
def _restore_insert_mode(self: AppProtocol) -> None:

0 commit comments

Comments
 (0)