Skip to content

Python scraper based on AI

fix: refactoring of fetch_node qixed error

Matteo Vedovati1ea2ad8e79e9
diff --git a/scrapegraphai/nodes/fetch_node.py b/scrapegraphai/nodes/fetch_node.py
index 4fbb42a9..02d2c946 100644
--- a/scrapegraphai/nodes/fetch_node.py
+++ b/scrapegraphai/nodes/fetch_node.py
@@ -120,13 +120,12 @@ class FetchNode(BaseNode):
if input_type in handlers:
return handlers[input_type](state, input_type, source)
elif self.input == "pdf_dir":
- pass
+ return state
elif not source.startswith("http"):
return self.handle_local_source(state, source)
else:
return self.handle_web_source(state, source)
-
def handle_directory(self, state, input_type, source):
"""
Handles the directory by compressing the source document and updating the state.