mirror of
https://github.com/github/codeql-action.git
synced 2025-12-06 07:48:17 +08:00
Check for 403 status
This commit is contained in:
2
lib/analyze-action.js
generated
2
lib/analyze-action.js
generated
@@ -83647,7 +83647,7 @@ function wrapApiConfigurationError(e) {
|
||||
"Please check that your token is valid and has the required permissions: contents: read, security-events: write"
|
||||
);
|
||||
}
|
||||
if (isEnablementError(httpError.message)) {
|
||||
if (httpError.status === 403 && isEnablementError(httpError.message)) {
|
||||
return new ConfigurationError(
|
||||
getFeatureEnablementError(httpError.message)
|
||||
);
|
||||
|
||||
2
lib/init-action-post.js
generated
2
lib/init-action-post.js
generated
@@ -116784,7 +116784,7 @@ function wrapApiConfigurationError(e) {
|
||||
"Please check that your token is valid and has the required permissions: contents: read, security-events: write"
|
||||
);
|
||||
}
|
||||
if (isEnablementError(httpError.message)) {
|
||||
if (httpError.status === 403 && isEnablementError(httpError.message)) {
|
||||
return new ConfigurationError(
|
||||
getFeatureEnablementError(httpError.message)
|
||||
);
|
||||
|
||||
2
lib/init-action.js
generated
2
lib/init-action.js
generated
@@ -80952,7 +80952,7 @@ function wrapApiConfigurationError(e) {
|
||||
"Please check that your token is valid and has the required permissions: contents: read, security-events: write"
|
||||
);
|
||||
}
|
||||
if (isEnablementError(httpError.message)) {
|
||||
if (httpError.status === 403 && isEnablementError(httpError.message)) {
|
||||
return new ConfigurationError(
|
||||
getFeatureEnablementError(httpError.message)
|
||||
);
|
||||
|
||||
2
lib/setup-codeql-action.js
generated
2
lib/setup-codeql-action.js
generated
@@ -79301,7 +79301,7 @@ function wrapApiConfigurationError(e) {
|
||||
"Please check that your token is valid and has the required permissions: contents: read, security-events: write"
|
||||
);
|
||||
}
|
||||
if (isEnablementError(httpError.message)) {
|
||||
if (httpError.status === 403 && isEnablementError(httpError.message)) {
|
||||
return new ConfigurationError(
|
||||
getFeatureEnablementError(httpError.message)
|
||||
);
|
||||
|
||||
2
lib/upload-lib.js
generated
2
lib/upload-lib.js
generated
@@ -82172,7 +82172,7 @@ function wrapApiConfigurationError(e) {
|
||||
"Please check that your token is valid and has the required permissions: contents: read, security-events: write"
|
||||
);
|
||||
}
|
||||
if (isEnablementError(httpError.message)) {
|
||||
if (httpError.status === 403 && isEnablementError(httpError.message)) {
|
||||
return new ConfigurationError(
|
||||
getFeatureEnablementError(httpError.message)
|
||||
);
|
||||
|
||||
2
lib/upload-sarif-action.js
generated
2
lib/upload-sarif-action.js
generated
@@ -82217,7 +82217,7 @@ function wrapApiConfigurationError(e) {
|
||||
"Please check that your token is valid and has the required permissions: contents: read, security-events: write"
|
||||
);
|
||||
}
|
||||
if (isEnablementError(httpError.message)) {
|
||||
if (httpError.status === 403 && isEnablementError(httpError.message)) {
|
||||
return new ConfigurationError(
|
||||
getFeatureEnablementError(httpError.message)
|
||||
);
|
||||
|
||||
@@ -318,7 +318,7 @@ export function wrapApiConfigurationError(e: unknown) {
|
||||
"Please check that your token is valid and has the required permissions: contents: read, security-events: write",
|
||||
);
|
||||
}
|
||||
if (isEnablementError(httpError.message)) {
|
||||
if (httpError.status === 403 && isEnablementError(httpError.message)) {
|
||||
return new ConfigurationError(
|
||||
getFeatureEnablementError(httpError.message),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user