@zeplin/cli
Advanced tools
Comparing version 0.1.1 to 0.1.2
{ | ||
"name": "@zeplin/cli", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"description": "Zeplin CLI", | ||
@@ -24,8 +24,8 @@ "main": "./dist/src/app", | ||
"type": "git", | ||
"url": "git+https://github.com/zeplin/zeplin-cli.git" | ||
"url": "git+https://github.com/zeplin/cli.git" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/zeplin/zeplin-cli/issues" | ||
"url": "https://github.com/zeplin/cli/issues" | ||
}, | ||
"homepage": "https://github.com/zeplin/zeplin-cli#readme", | ||
"homepage": "https://github.com/zeplin/cli#readme", | ||
"devDependencies": { | ||
@@ -32,0 +32,0 @@ "@types/express": "^4.17.2", |
@@ -18,2 +18,3 @@ "use strict"; | ||
const errors_1 = require("../errors"); | ||
const http_status_codes_1 = require("http-status-codes"); | ||
const LOGIN_URL = "/users/login"; | ||
@@ -55,5 +56,7 @@ const AUTHORIZE_URL = "/oauth/authorize"; | ||
headers: { "Zeplin-Token": zeplinToken }, | ||
maxRedirects: 0 | ||
maxRedirects: 0, | ||
validateStatus: (status) => status === http_status_codes_1.MOVED_TEMPORARILY | ||
}); | ||
const responseParams = new URLSearchParams(response.data.split("?")); | ||
const [, responseQueryParams] = response.data.split("?"); | ||
const responseParams = new URLSearchParams(responseQueryParams); | ||
return responseParams.get("access_token"); | ||
@@ -60,0 +63,0 @@ } |
{ | ||
"name": "@zeplin/cli", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"description": "Zeplin CLI", | ||
@@ -24,8 +24,8 @@ "main": "./dist/src/app", | ||
"type": "git", | ||
"url": "git+https://github.com/zeplin/zeplin-cli.git" | ||
"url": "git+https://github.com/zeplin/cli.git" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/zeplin/zeplin-cli/issues" | ||
"url": "https://github.com/zeplin/cli/issues" | ||
}, | ||
"homepage": "https://github.com/zeplin/zeplin-cli#readme", | ||
"homepage": "https://github.com/zeplin/cli#readme", | ||
"devDependencies": { | ||
@@ -32,0 +32,0 @@ "@types/express": "^4.17.2", |
Sorry, the diff of this file is not supported yet
105254
1531
6