-
Notifications
You must be signed in to change notification settings - Fork 10
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
Enhance BaseToggle with additional enabled/disabled toggle methods #290
Comments
Hello @robrap can i work on this ? |
That would be great @Theo-flux. Let me know if you have any questions. |
@Theo-flux: As part of this work, it might be good to share the proposal and get feedback, in case anyone has any better ideas on naming. Would you want to start a discussion in discuss.openedx.org about this proposal? |
|
Just opened a discussion on openedx now https://discuss.openedx.org/t/ideas-for-naming-methods-in-a-class/10630/1 |
Thank you! Also, it will be pretty quick to search/replace your code if someone suggest a good change in the next day or two, so feel free to start the PR in parallel. |
OK @robrap sounds great! Let me set things up from end. I'll let you know when I have question(s) to ask. Thanks |
@robrap kindly check my PR. Not all checks passed. I already filled the contribution form. I am yet to get the document so I can sign on it. Thanks! |
@robrap I am still yet to receive the CLA document. I hope this is not an error |
@Theo-flux: Once the CLA gets worked out (which it will), I can do the review. Thank you! |
[inform] This ticket is available for work. @Theo-flux was almost able to complete this in this PR: #293. It just needs some minor work to get it over the line. Thanks again @Theo-flux for your contribution. |
Enhance BaseToggle with additional methods.
Add the following:
is_enabled
.is_enabled
.is_enabled
.This should make a variety of conditions more readable when
ENABLE_
orDISABLE_
are in the toggle name.Example 1:
is_disabled
Example 2:
is_toggled_off
Notes:
DISABLE_FEATURE
toggle, the toggle is off when the feature is on, so we use_toggle_
in the method nameis_toggled_off
to clearly refer to the toggle and not the feature.Questions:
Is this in fact simpler to understand? Are there better options?Work required:
The text was updated successfully, but these errors were encountered: