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

Type fixes #49

Merged
merged 5 commits into from
Nov 5, 2024
Merged

Type fixes #49

merged 5 commits into from
Nov 5, 2024

Conversation

erik-perri
Copy link
Member

When I was adding more explicit typing for the modifier callbacks I typed them as void since we didn't use the result in the functions. This left existing code that used the modifier with an arrow function producing static analysis errors since they return the rule from the function. To fix it I made the modifier argument support functions that return void or the expected rule, then treat it as mutable when void is returned and replace the rule when not (most rules are mutable so this will have no effect in most cases, it is just in case someone replaces completely in the modifier).

@erik-perri erik-perri merged commit 7aebad8 into master Nov 5, 2024
4 checks passed
@erik-perri erik-perri deleted the type-fixes branch November 5, 2024 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants