lib/twitter/base.rb in twitter-4.5.0 vs lib/twitter/base.rb in twitter-4.6.0
- old
+ new
@@ -91,10 +91,12 @@
# Retrieve the attributes of an object
#
# @return [Hash]
def attrs
- @attrs
+ @attrs.inject({}) do |attrs, (key, value)|
+ attrs.merge!(key => respond_to?(key) ? send(key) : value)
+ end
end
alias to_hash attrs
# Update the attributes of an object
#