Skip to content

Commit d59c474

Browse files
authored
Merge pull request #20 from LucasAlvws/feat/browserSet_download_path
feat: set_download_path added in browser class methods
2 parents ec97ccf + e78eddc commit d59c474

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

pydoll/browser/base.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,16 @@ async def start(self) -> None:
120120
][0]['targetId']
121121
self._pages.append(valid_page)
122122

123+
async def set_download_path(self, path: str):
124+
"""
125+
Sets the download path for the browser.
126+
Args:
127+
path (str): The path to the download directory.
128+
"""
129+
await self._execute_command(
130+
BrowserCommands.set_download_path(path)
131+
)
132+
123133
async def get_page(self) -> Page:
124134
"""
125135
Retrieves a Page instance for an existing page in the browser.

0 commit comments

Comments
 (0)