提交 2e4aa39e 编写于 作者: X Xavier Noria

Merge pull request #9194 from kwstannard/2-3-stable

Docs: Fixed bad exists? documentation.
......@@ -867,10 +867,11 @@ Client.exists?(1,2,3)
Client.exists?([1,2,3])
</ruby>
Further more, +exists+ takes a +conditions+ option much like find:
Further more, +exists+ takes a hash or array like what you would pass into a +conditions+ option:
<ruby>
Client.exists?(:conditions => "first_name = 'Ryan'")
Client.exists?(:first_name => 'Ryan')
Client.exists?(['first_name = ?', 'Ryan'])
</ruby>
It's even possible to use +exists?+ without any arguments:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册