File tree Expand file tree Collapse file tree 1 file changed +4
-12
lines changed Expand file tree Collapse file tree 1 file changed +4
-12
lines changed Original file line number Diff line number Diff line change @@ -226,25 +226,17 @@ def get_procs( symbol, name )
226
226
return nil if @procs . size == 0
227
227
@procs . find_all do |sym , match , block |
228
228
(
229
- ( sym . nil? or symbol == sym ) and
230
- ( ( name . nil? and match . nil? ) or match . nil? or (
231
- ( name == match ) or
232
- ( match . kind_of? Regexp and name =~ match )
233
- )
234
- )
229
+ ( sym . nil? or ( symbol == sym ) ) and
230
+ ( match . nil? or ( name == match ) or ( match . kind_of? Regexp and match . match? ( name ) ) )
235
231
)
236
232
end . collect { |x | x [ -1 ] }
237
233
end
238
234
def get_listeners ( symbol , name )
239
235
return nil if @listeners . size == 0
240
236
@listeners . find_all do |sym , match , block |
241
237
(
242
- ( sym . nil? or symbol == sym ) and
243
- ( ( name . nil? and match . nil? ) or match . nil? or (
244
- ( name == match ) or
245
- ( match . kind_of? Regexp and name =~ match )
246
- )
247
- )
238
+ ( sym . nil? or ( symbol == sym ) ) and
239
+ ( match . nil? or ( name == match ) or ( match . kind_of? Regexp and match . match? ( name ) ) )
248
240
)
249
241
end . collect { |x | x [ -1 ] }
250
242
end
You can’t perform that action at this time.
0 commit comments