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

Add isHidden to RecipeMaps to hide the default RecipeMapCategory #1652

Merged
merged 1 commit into from
Jun 28, 2021
Merged

Add isHidden to RecipeMaps to hide the default RecipeMapCategory #1652

merged 1 commit into from
Jun 28, 2021

Conversation

bruberu
Copy link
Contributor

@bruberu bruberu commented Jun 3, 2021

What:
This particular PR solves a problem with RecipeMaps, where the auto-generated RecipeMapCategory could not be stopped from being registered. For RecipeMaps with particularly notable features that required them to gain a new wrapper and category, this issue prevented them from stopping the registration of the default.

How solved:
To fix this, I added a boolean, isHidden, which when true, would prevent the default category from being registered. I made sure to add this through a new constructor in RecipeMap, which is linked to by the old one, to prevent compatibility issues.

Outcome:
Allows for default RecipeMapCategories to be hidden.

Additional info:
You may have noticed that I created a very similar PR a few hours ago. However, since my knowledge of Git is quite poor, that repository was riddled with duplicate commits, and as such, I was forced to delete it.

Possible compatibility issue:
Since the normal RecipeMap constructor is still used in this PR, and works as intended for the end user, there shouldn't be any compatibillity issues here.

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

Successfully merging this pull request may close these issues.

3 participants