Skip to content

A platform for community discussion. Free, open, simple.

REFACTOR: Remove `Discourse.SiteSettings` from reply adapter

Robin Wardf5adf6d183ca
diff --git a/app/assets/javascripts/discourse/app/adapters/post-reply-history.js b/app/assets/javascripts/discourse/app/adapters/post-reply-history.js
index b90cfbb5e37..82554140e6e 100644
--- a/app/assets/javascripts/discourse/app/adapters/post-reply-history.js
+++ b/app/assets/javascripts/discourse/app/adapters/post-reply-history.js
@@ -3,7 +3,7 @@ import RestAdapter from "discourse/adapters/rest";
export default RestAdapter.extend({
find(store, type, findArgs) {
- const maxReplies = Discourse.SiteSettings.max_reply_history;
+ const maxReplies = this.siteSettings.max_reply_history;
return ajax(
`/posts/${findArgs.postId}/reply-history?max_replies=${maxReplies}`
).then(replies => {