lib/safemode/blankslate.rb in safemode-1.2.0 vs lib/safemode/blankslate.rb in safemode-1.2.1

- old
+ new

@@ -1,7 +1,7 @@ module Safemode class Blankslate - @@allow_instance_methods = ['class', 'inspect', 'methods', 'respond_to?', 'to_s', 'instance_variable_get'] + @@allow_instance_methods = ['class', 'inspect', 'methods', 'respond_to?', 'respond_to_missing?', 'to_s', 'instance_variable_get'] @@allow_class_methods = ['methods', 'new', 'name', 'inspect', '<', 'ancestors', '=='] # < needed in Rails Object#subclasses_of silently { undef_methods(*instance_methods.map(&:to_s) - @@allow_instance_methods) } class << self silently { undef_methods(*instance_methods.map(&:to_s) - @@allow_class_methods) }