enforce coding convention

replaced every `and` by `&&` and every `or` by `||`
This commit is contained in:
Régis Hanol
2013-03-05 01:42:44 +01:00
parent f544e1d4f7
commit 239cbd2d58
39 changed files with 75 additions and 76 deletions

View File

@@ -11,7 +11,7 @@ class TopicView
# Special case: If the topic is private and the user isn't logged in, ask them
# to log in!
if @topic.present? and @topic.private_message? and user.blank?
if @topic.present? && @topic.private_message? && user.blank?
raise Discourse::NotLoggedIn.new
end
@@ -52,7 +52,7 @@ class TopicView
def next_page
last_post = @posts.last
if last_post.present? and (@topic.highest_post_number > last_post.post_number)
if last_post.present? && (@topic.highest_post_number > last_post.post_number)
(@posts[0].post_number / SiteSetting.posts_per_page) + 1
end
end