We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9cf45eb commit abda367Copy full SHA for abda367
1 file changed
sqlparse/filters/aligned_indent.py
@@ -38,7 +38,8 @@ def nl(self, offset=1):
38
self._max_kwd_len + offset + indent + self.offset))
39
40
def _process_statement(self, tlist):
41
- if tlist.tokens[0].is_whitespace and self.indent == 0:
+ if len(tlist.tokens) > 0 and tlist.tokens[0].is_whitespace \
42
+ and self.indent == 0:
43
tlist.tokens.pop(0)
44
45
# process the main query body
0 commit comments