mirror of
https://github.com/discourse/discourse.git
synced 2026-09-05 04:40:41 -05:00
Add setter for excerpt_size so plugins can set it more easily
This commit is contained in:
+5
-1
@@ -157,8 +157,12 @@ class Post < ActiveRecord::Base
|
||||
includes(:post_details).find_by(post_details: { key: key, value: value })
|
||||
end
|
||||
|
||||
def self.excerpt_size=(sz)
|
||||
@excerpt_size = sz
|
||||
end
|
||||
|
||||
def self.excerpt_size
|
||||
220
|
||||
@excerpt_size || 220
|
||||
end
|
||||
|
||||
def whisper?
|
||||
|
||||
Reference in New Issue
Block a user