mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
PERF: shift most user options out of the user table
As it stands we load up user records quite frequently on the topic pages, this in turn pulls all the columns for the users being selected, just to discard them after they are loaded New structure keeps all options in a discrete table, this is better organised and allows us to easily add more column without worrying about bloating the user table
This commit is contained in:
@@ -157,7 +157,7 @@ module PostGuardian
|
||||
return false unless post
|
||||
|
||||
if !post.hidden
|
||||
return true if post.wiki || SiteSetting.edit_history_visible_to_public || post.user.try(:edit_history_public)
|
||||
return true if post.wiki || SiteSetting.edit_history_visible_to_public || (post.user && post.user.user_option.edit_history_public)
|
||||
end
|
||||
|
||||
authenticated? &&
|
||||
|
||||
Reference in New Issue
Block a user