提交 cd837758 编写于 作者: Y yui-knk

[ci skip] Check a result of `valid?` instead of `create`

上级 34640210
......@@ -69,7 +69,8 @@ module Helpers
# controller gets a nested hash <tt>params[:person]</tt> with the person attributes
# set in the form. That hash is ready to be passed to <tt>Person.create</tt>:
#
# if @person = Person.create(params[:person])
# @person = Person.create(params[:person])
# if @person.valid?
# # success
# else
# # error handling
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册