Skip to content

Commit 76a833f

Browse files
committed
refactor: change screenshot format from PNG to JPG in commands and element
1 parent 9fea0e8 commit 76a833f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

pydoll/commands/page.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def set_download_path(cls, path: str) -> dict:
5151

5252
@classmethod
5353
def screenshot(
54-
cls, format: str = 'png', quality: int = 100, clip: dict = None
54+
cls, format: str = 'jpg', quality: int = 100, clip: dict = None
5555
) -> dict:
5656
"""
5757
Generates the command to capture a screenshot of the current page.

pydoll/element.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ async def get_screenshot(self, path: str):
190190
}
191191
screenshot = await self._connection_handler.execute_command(
192192
PageCommands.screenshot(
193-
format='png', clip=clip
193+
format='jpg', clip=clip
194194
)
195195
)
196196
async with aiofiles.open(path, 'wb') as file:

0 commit comments

Comments
 (0)