From ca91190291750d0293543bb9e0c7bd5f0da67e9a Mon Sep 17 00:00:00 2001 From: Sawyer Date: Fri, 25 Jul 2025 00:35:20 -0500 Subject: [PATCH] style: use self.config directly instead of assigning a variable --- proxy.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/proxy.py b/proxy.py index c86bc5f..18c87fe 100644 --- a/proxy.py +++ b/proxy.py @@ -40,14 +40,11 @@ class Scraper: driver.quit() def _setup_driver(self): - headless = self.config.headless - user_agent = self.config.user_agent - chrome_options = ChromeOptions() - chrome_options.add_argument(f"--user-agent={user_agent}") + chrome_options.add_argument(f"--user-agent={self.config.user_agent}") self.driver = uc.Chrome( - headless=headless, + headless=self.config.headless, options=chrome_options, use_subprocess=False )