Method: AnnotationSecurity::Utils.method_body

Defined in:
lib/annotation_security/utils.rb

.method_body(method) ⇒ Object

Removes pre- and suffixes from method, returns nil if no change was made.



15
16
17
18
# File 'lib/annotation_security/utils.rb', line 15

def self.method_body(method)
  body = method.to_s.gsub(PREFIXES,'').gsub(SUFFIXES,'')
  method.to_s == body ? nil : body
end