Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
marcogario committed Jul 1, 2024
1 parent dbfc2b6 commit ddd849e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/api-client.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/api-client.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions src/api-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,9 @@ export async function getWorkflowRelativePath(): Promise<string> {
);
const workflowUrl = runsResponse.data.workflow_url;

const requiredWorkflowRegex = /\/repos\/[^/]+\/[^/]+\/actions\/required_workflows\/[^/]+/;
if (!workflowUrl || requiredWorkflowRegex.test(workflowUrl)) {
const requiredWorkflowRegex =
/\/repos\/[^/]+\/[^/]+\/actions\/required_workflows\/[^/]+/;
if (!workflowUrl || requiredWorkflowRegex.test(workflowUrl as string)) {
// For required workflows, the workflowUrl is invalid so we cannot fetch more informations
// about the workflow.
// However, the path is available in the original response.
Expand Down

0 comments on commit ddd849e

Please sign in to comment.