diff options
Diffstat (limited to 'lib/rexml/parsers/sax2parser.rb')
-rw-r--r-- | lib/rexml/parsers/sax2parser.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rexml/parsers/sax2parser.rb b/lib/rexml/parsers/sax2parser.rb index 4cddc4806..2280b983a 100644 --- a/lib/rexml/parsers/sax2parser.rb +++ b/lib/rexml/parsers/sax2parser.rb @@ -185,7 +185,7 @@ module REXML end def add( pair ) - if pair[-1].kind_of? Proc or (defined? Block and pair[-1].kind_of? Block) + if pair[-1].respond_to? :call @procs << pair unless @procs.include? pair else @listeners << pair unless @listeners.include? pair |