@octokit/request-error
Advanced tools
Comparing version 1.0.1 to 1.0.2
@@ -42,7 +42,9 @@ 'use strict'; | ||
}); | ||
} // client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
} | ||
requestCopy.url = requestCopy.url // client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
// see https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications | ||
requestCopy.url = requestCopy.url.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]"); | ||
.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]") // OAuth tokens can be passed as URL query parameters, although it is not recommended | ||
// see https://developer.github.com/v3/#oauth2-token-sent-in-a-header | ||
.replace(/\baccess_token=\w+/g, "access_token=[REDACTED]"); | ||
this.request = requestCopy; | ||
@@ -49,0 +51,0 @@ } |
@@ -31,7 +31,11 @@ import { Deprecation } from "deprecation"; | ||
} | ||
// client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
// see https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications | ||
requestCopy.url = requestCopy.url.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]"); | ||
requestCopy.url = requestCopy.url | ||
// client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
// see https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications | ||
.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]") | ||
// OAuth tokens can be passed as URL query parameters, although it is not recommended | ||
// see https://developer.github.com/v3/#oauth2-token-sent-in-a-header | ||
.replace(/\baccess_token=\w+/g, "access_token=[REDACTED]"); | ||
this.request = requestCopy; | ||
} | ||
} |
@@ -126,7 +126,9 @@ class Deprecation extends Error { | ||
}); | ||
} // client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
} | ||
requestCopy.url = requestCopy.url // client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
// see https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications | ||
requestCopy.url = requestCopy.url.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]"); | ||
.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]") // OAuth tokens can be passed as URL query parameters, although it is not recommended | ||
// see https://developer.github.com/v3/#oauth2-token-sent-in-a-header | ||
.replace(/\baccess_token=\w+/g, "access_token=[REDACTED]"); | ||
this.request = requestCopy; | ||
@@ -133,0 +135,0 @@ } |
@@ -36,7 +36,9 @@ import { Deprecation } from 'deprecation'; | ||
}); | ||
} // client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
} | ||
requestCopy.url = requestCopy.url // client_id & client_secret can be passed as URL query parameters to increase rate limit | ||
// see https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications | ||
requestCopy.url = requestCopy.url.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]"); | ||
.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]") // OAuth tokens can be passed as URL query parameters, although it is not recommended | ||
// see https://developer.github.com/v3/#oauth2-token-sent-in-a-header | ||
.replace(/\baccess_token=\w+/g, "access_token=[REDACTED]"); | ||
this.request = requestCopy; | ||
@@ -43,0 +45,0 @@ } |
{ | ||
"name": "@octokit/request-error", | ||
"description": "Error class for Octokit request errors", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"license": "MIT", | ||
@@ -6,0 +6,0 @@ "files": [ |
15133
294