Skip to content

Conversation

@amaskara-dd
Copy link
Contributor

@amaskara-dd amaskara-dd commented Jun 25, 2025

npx tsc --skipLibCheck

@amaskara-dd amaskara-dd requested a review from a team as a code owner June 25, 2025 18:28
status = "failure";
}
}
const contextName = checkName ? checkName : context.repo.repo;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟠 Code Quality Violation

Suggested change
const contextName = checkName ? checkName : context.repo.repo;
const contextName = checkName || context.repo.repo;
Avoid unnecessary ternary (...read more)

This rule advises against the use of unnecessary ternary operations that return a boolean value. In JavaScript, the ternary operator ? : is a shorthand way of writing an if-else statement. However, if the result of the ternary operation is a boolean (such as true or false), it is often unnecessary because the condition itself already produces a boolean value.

The use of unnecessary ternary operations can lead to code that is harder to read and understand. Furthermore, it can lead to potential bugs if the ternary operation is not correctly written or understood. To adhere to this rule, you should return the condition itself rather than using a ternary operation.

View in Datadog  Leave us feedback  Documentation

status = "failure";
}
}
const contextName = checkName ? checkName : github_1.context.repo.repo;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟠 Code Quality Violation

Suggested change
const contextName = checkName ? checkName : github_1.context.repo.repo;
const contextName = checkName || github_1.context.repo.repo;
Avoid unnecessary ternary (...read more)

This rule advises against the use of unnecessary ternary operations that return a boolean value. In JavaScript, the ternary operator ? : is a shorthand way of writing an if-else statement. However, if the result of the ternary operation is a boolean (such as true or false), it is often unnecessary because the condition itself already produces a boolean value.

The use of unnecessary ternary operations can lead to code that is harder to read and understand. Furthermore, it can lead to potential bugs if the ternary operation is not correctly written or understood. To adhere to this rule, you should return the condition itself rather than using a ternary operation.

View in Datadog  Leave us feedback  Documentation

armcburney
armcburney previously approved these changes Jun 25, 2025
Copy link

@gabepales gabepales left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants