提交 9dccf008 编写于 作者: C Carlos Antonio da Silva

Fix code example in ActiveRecord::Relation#none

上级 d2c64009
...@@ -216,11 +216,11 @@ def lock(locks = true) ...@@ -216,11 +216,11 @@ def lock(locks = true)
# #
# def visible_posts # def visible_posts
# case role # case role
# if 'Country Manager' # when 'Country Manager'
# Post.where(:country => country) # Post.where(:country => country)
# if 'Reviewer' # when 'Reviewer'
# Post.published # Post.published
# if 'Bad User' # when 'Bad User'
# Post.none # => returning [] instead breaks the previous code # Post.none # => returning [] instead breaks the previous code
# end # end
# end # end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册