summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorLadislav Gallay <ladislav.gallay@lentil.sk>2022-01-18 14:54:52 +0100
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2022-03-07 20:08:22 +0900
commite1391bf96f03143387c500a168adb6fc9fc242c6 (patch)
treeb4fbbe791e892d4f039396511ec159b0538860ab /lib
parent1dd2d2ce48d7ed0e16beb42ac923ccd069701958 (diff)
[ruby/ostruct] Fix class and method as attribute names
https://github.com/ruby/ostruct/commit/7258535073
Diffstat (limited to 'lib')
-rw-r--r--lib/ostruct.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ostruct.rb b/lib/ostruct.rb
index 4dccfc4c63..2b739beed7 100644
--- a/lib/ostruct.rb
+++ b/lib/ostruct.rb
@@ -246,7 +246,7 @@ class OpenStruct
if owner.class == ::Class
owner < ::OpenStruct
else
- self.class.ancestors.any? do |mod|
+ self.class!.ancestors.any? do |mod|
return false if mod == ::OpenStruct
mod == owner
end