summaryrefslogtreecommitdiff
path: root/sqlparse/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'sqlparse/utils.py')
-rw-r--r--sqlparse/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/sqlparse/utils.py b/sqlparse/utils.py
index 66dd8bc..90acb5c 100644
--- a/sqlparse/utils.py
+++ b/sqlparse/utils.py
@@ -166,7 +166,7 @@ def imt(token, i=None, m=None, t=None):
def find_matching(tlist, token, M1, M2):
idx = tlist.token_index(token)
depth = 0
- for token in tlist[idx:]:
+ for token in tlist.tokens[idx:]:
if token.match(*M1):
depth += 1
elif token.match(*M2):