2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-06 10:50:21 +08:00

added profile environment for perftools profiling (1.9.3 only)

This commit is contained in:
Sam 2013-03-10 17:21:56 -07:00
parent 45c4382cce
commit 22a4580df5
8 changed files with 73 additions and 2 deletions

View file

@ -123,6 +123,7 @@ class Topic < ActiveRecord::Base
return title unless SiteSetting.title_fancy_entities?
# We don't always have to require this, if fancy is disabled
# see: http://meta.discourse.org/t/pattern-for-defer-loading-gems-and-profiling-with-perftools-rb/4629
require 'redcarpet' unless defined? Redcarpet
Redcarpet::Render::SmartyPants.render(title)