Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrades apr 2021 #180

Merged
merged 3 commits into from Apr 7, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 1 addition & 2 deletions .eslintrc.json
Expand Up @@ -16,8 +16,7 @@
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking",
"prettier",
"prettier/@typescript-eslint"
"prettier"
],
"rules": {}
}
5 changes: 2 additions & 3 deletions package.json
Expand Up @@ -38,7 +38,7 @@
"lodash": "^4.17.20",
"mkdirp": "^1.0.4",
"proxy-agent": "^4.0.0",
"puppeteer": "^5.5.0",
"puppeteer": "^8.0.0",
"uuid": "^8.3.2"
},
"devDependencies": {
Expand All @@ -50,12 +50,11 @@
"@types/lodash": "^4.14.167",
"@types/mkdirp": "^1.0.1",
"@types/node": "^14.14.20",
"@types/puppeteer": "^5.4.2",
"@types/uuid": "^8.3.0",
"@typescript-eslint/eslint-plugin": "^4.12.0",
"@typescript-eslint/parser": "^4.12.0",
"eslint": "^7.17.0",
"eslint-config-prettier": "^7.1.0",
"eslint-config-prettier": "^8.1.0",
"prettier": "^2.2.1",
"ts-node-dev": "^1.1.1",
"typescript": "^4.1.3"
Expand Down
5 changes: 3 additions & 2 deletions src/login.ts
Expand Up @@ -5,7 +5,7 @@ import zlib from "zlib";
import AWS from "aws-sdk";
import cheerio from "cheerio";
import { v4 } from "uuid";
import puppeteer from "puppeteer";
import puppeteer, { HTTPRequest } from "puppeteer";
import querystring from "querystring";
import _debug from "debug";
import { CLIError } from "./CLIError";
Expand Down Expand Up @@ -659,7 +659,7 @@ export const login = {
// Prevent redirection to AWS
let samlResponseData;
const samlResponsePromise = new Promise((resolve) => {
page.on("request", (req) => {
page.on("request", (req: HTTPRequest) => {
const reqURL = req.url();
debug(`Request: ${url}`);
if (
Expand All @@ -673,6 +673,7 @@ export const login = {
req.respond({
status: 200,
contentType: "text/plain",
headers: {},
body: "",
});
if (browser) {
Expand Down