Updated version of 'sqlparse' as pgcli updated and tested it.

This commit is contained in:
Akshay Joshi
2020-12-14 11:39:50 +05:30
parent c79614786f
commit 296d22ad83
2 changed files with 2 additions and 2 deletions

View File

@@ -16,7 +16,7 @@ TableExpression = namedtuple("TableExpression", "name columns start stop")
def isolate_query_ctes(full_text, text_before_cursor):
"""Simplify a query by converting CTEs into table metadata objects"""
if not full_text:
if not full_text or not full_text.strip():
return full_text, text_before_cursor, tuple()
ctes, remainder = extract_ctes(full_text)