提交 55975c71 编写于 作者: A Aaron Patterson

just call the class method since we know the callbacks are stored at the

class level
上级 920753f3
......@@ -76,7 +76,8 @@ module Callbacks
# save
# end
def run_callbacks(kind, &block)
cbs = send("_#{kind}_callbacks")
cbs = self.class.send("_#{kind}_callbacks")
if cbs.empty?
yield if block_given?
else
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册