mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
PERF: Rendering crawler's template is expensive.
This commit is contained in:
committed by
Régis Hanol
parent
3d4cdd7040
commit
4e7e4cee7d
@@ -169,8 +169,12 @@ module ApplicationHelper
|
||||
MobileDetection.resolve_mobile_view!(request.user_agent,params,session)
|
||||
end
|
||||
|
||||
def crawler_layout?
|
||||
controller.try(:use_crawler_layout?)
|
||||
end
|
||||
|
||||
def include_crawler_content?
|
||||
controller.try(:use_crawler_layout?) || !mobile_view?
|
||||
crawler_layout? || !mobile_view?
|
||||
end
|
||||
|
||||
def mobile_device?
|
||||
|
||||
Reference in New Issue
Block a user