summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sqlparse/filters.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/sqlparse/filters.py b/sqlparse/filters.py
index 291a613..9ee2ce0 100644
--- a/sqlparse/filters.py
+++ b/sqlparse/filters.py
@@ -110,17 +110,15 @@ class IncludeStatement:
elif self.detected:
# Omit whitespaces
if token_type in Whitespace:
- pass
-
- # Get path of file to include
- path = None
+ continue
+ # Found file path to include
if token_type in String.Symbol:
# if token_type in tokens.String.Symbol:
+
+ # Get path of file to include
path = join(self.dirpath, value[1:-1])
- # Include file if path was found
- if path:
try:
f = open(path)
raw_sql = f.read()