提交 63992e8f 编写于 作者: P Pratik Naik

Support Object#filter method for before/after filters

上级 669fd849
......@@ -326,6 +326,8 @@ def #{method_name}(&blk)
def #{method_name}(&blk)
if #{method_name}_object.respond_to?(:#{kind})
#{method_name}_object.#{kind}(self, &blk)
elsif #{method_name}_object.respond_to?(:filter)
#{method_name}_object.send("filter", self, &blk)
else
#{method_name}_object.send("#{kind}_#{name}", self, &blk)
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册