-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CHANGE @W-16891041@ FlowTest rules consolidated #135
Conversation
5a433f7
to
ffa4e75
Compare
ffa4e75
to
0f46cd4
Compare
4605333
to
2f07700
Compare
const consolidatedNames: Set<string> = new Set(getConsolidatedRuleNames()); | ||
const convertedRules: RuleDescription[] = [...consolidatedNames.values()].map(getConsolidatedRuleByName); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why use a set? Why not just do getConsolidatedRuleNames().map(getConsolidatedRuleByName)
?
b0c4ace
to
2f8cfd4
Compare
export function getConsolidatedRuleNames(): string[] { | ||
return [...QUERY_NAMES_TO_CONSOLIDATED_NAMES.values()]; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I see... you use a set in the other spot. I think it should be here to make things unique. So you could here do
[...new Set(QUERY_NAMES_TO_CONSOLIDATED_NAMES.values())]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider moving the location where you make the consolidatedRuleNames unique (i.e. apply the set inside of the getConsolidatedRuleNames function instead.
Otherwise, approve.
No description provided.