-
Notifications
You must be signed in to change notification settings - Fork 43
Allow instance_variable_get for gems than need low level acces #138
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -28,7 +28,7 @@ def self.included(base) | |
| end | ||
|
|
||
| module ClassMethods | ||
| SENSITIVE_INSTANCE_METHODS = %i[ instance_variable_get instance_variable_set ] | ||
| SENSITIVE_INSTANCE_METHODS = %i[ instance_variable_set ] | ||
|
|
||
|
Comment on lines
30
to
32
|
||
| def prevent_instance_data_manipulation | ||
| SENSITIVE_INSTANCE_METHODS.each do |method| | ||
|
|
||
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.
The surrounding documentation is now inaccurate: Freezeable no longer blocks
instance_variable_get, but the header comment still says it prevents “accessing … instance variables via reflection”, and the flag comment mentions bothinstance_variable_getandinstance_variable_set. Please update the comments (and/or renameprevent_instance_data_manipulation*if its meaning is now “prevent mutation”).