提交 ad957273 编写于 作者: R Ryuta Kamizono

Fix `_write_layout_method`

上级 d40c88ae
......@@ -306,12 +306,12 @@ def _write_layout_method # :nodoc:
RUBY
when Proc
define_method :_layout_from_proc, &_layout
private :_layout_from_proc
<<-RUBY
result = _layout_from_proc(#{_layout.arity == 0 ? '' : 'self'})
return #{default_behavior} if result.nil?
result
RUBY
private :_layout_from_proc
when false
nil
when true
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册