Skip to content

Commit

Permalink
Decode proxy credentials (#33)
Browse files Browse the repository at this point in the history
* decode proxy credentials

* update version
  • Loading branch information
mxsnq authored Aug 9, 2023
1 parent 9faaf63 commit 9173f53
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion helpers/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,10 @@ exports.getBrowserPage = async function getBrowserPage(browser, request) {
context[PROXY_URL_KEY] = proxy;
const page = await newPage(context);
if (username) {
await page.authenticate({ username, password });
await page.authenticate({
username: decodeURIComponent(username),
password: decodeURIComponent(password)
});
}
return page;
};
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "scrapy-puppeteer-service",
"version": "0.2.0",
"version": "0.2.1",
"private": true,
"scripts": {
"start": "node ./bin/www"
Expand Down

0 comments on commit 9173f53

Please sign in to comment.