Skip to content
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

feat(platforms): adding isDeprecated option to providers, reject verification #3087

Merged
merged 8 commits into from
Dec 4, 2024

Conversation

lucianHymer
Copy link
Collaborator

fixes #3034

@lucianHymer lucianHymer force-pushed the 3034-stamp-deprecation branch from 95afddc to ed9a75d Compare December 4, 2024 01:02
@lucianHymer lucianHymer force-pushed the 3034-stamp-deprecation branch from 6d5405b to 9aee965 Compare December 4, 2024 14:48
@lucianHymer lucianHymer marked this pull request as ready for review December 4, 2024 14:50

// Hide if deprecated and score is 0
const checkHiddenByDeprecation = () =>
provider.isDeprecated && parseFloat(stampScores[provider.name] || "0") <= 0;

Copy link
Collaborator

Choose a reason for hiding this comment

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

do checkHiddenByCustomization and checkHiddenByDeprecation need to be functions?
Why not compute the boolean value of the flag and store it in flags like isHiddenByCustomization and isHiddenByDeprecation ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Just to take advantage of short circuiting, especially if we add more conditions

Copy link
Collaborator

Choose a reason for hiding this comment

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

The question is what is cheaper?
a. to define a 2 functions on each iteration
b. or use if / else construct instead the short-circuit construct ...

@lucianHymer lucianHymer merged commit b18d319 into main Dec 4, 2024
2 checks passed
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.

Deprecation of the OutDid Stamp
2 participants