mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 15:48:43 -05:00
FEATURE: new site setting rebake_old_posts_count
This commit is contained in:
parent
0433163866
commit
a2220feaea
3 changed files with 6 additions and 1 deletions
|
@ -29,7 +29,7 @@ module Jobs
|
|||
|
||||
# Forces rebake of old posts where needed, as long as no system avatars need updating
|
||||
unless UserAvatar.where("last_gravatar_download_attempt IS NULL").limit(1).first
|
||||
problems = Post.rebake_old(250)
|
||||
problems = Post.rebake_old(SiteSetting.rebake_old_posts_count)
|
||||
problems.each do |hash|
|
||||
post_id = hash[:post].id
|
||||
Discourse.handle_job_exception(hash[:ex], error_context(args, "Rebaking post id #{post_id}", post_id: post_id))
|
||||
|
|
|
@ -1029,6 +1029,8 @@ en:
|
|||
top_topics_formula_first_post_likes_multiplier: "value of first post likes multiplier (n) in top topics formula: `log(views_count) * 2 + op_likes_count * (n) + LEAST(likes_count / posts_count, 3) + 10 + log(posts_count)`"
|
||||
top_topics_formula_least_likes_per_post_multiplier: "value of least likes per post multiplier (n) in top topics formula: `log(views_count) * 2 + op_likes_count * 0.5 + LEAST(likes_count / posts_count, (n)) + 10 + log(posts_count)`"
|
||||
|
||||
rebake_old_posts_count: "Number of old posts to be rebaked every 15 minutes."
|
||||
|
||||
rate_limit_create_topic: "After creating a topic, users must wait (n) seconds before creating another topic."
|
||||
rate_limit_create_post: "After posting, users must wait (n) seconds before creating another post."
|
||||
rate_limit_new_user_create_topic: "After creating a topic, new users must wait (n) seconds before creating another topic."
|
||||
|
|
|
@ -942,6 +942,9 @@ developer:
|
|||
top_topics_formula_least_likes_per_post_multiplier:
|
||||
default: 3
|
||||
min: 0
|
||||
rebake_old_posts_count:
|
||||
default: 250
|
||||
min: 1
|
||||
migrate_to_new_scheme:
|
||||
hidden: true
|
||||
default: false
|
||||
|
|
Loading…
Reference in a new issue