mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 07:53:49 +08:00
DEV: Allow new_features URL to be configurable (#24306)
This is so the new features plugin can be tested easier locally.
This commit is contained in:
@ -218,6 +218,11 @@ module DiscourseUpdates
|
||||
)
|
||||
end
|
||||
|
||||
def new_features_endpoint
|
||||
return "https://meta.discourse.org/new-features.json" if Rails.env.production?
|
||||
ENV["DISCOURSE_NEW_FEATURES_ENDPOINT"] || "http://localhost:4200/new-features.json"
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def last_installed_version_key
|
||||
@ -248,10 +253,6 @@ module DiscourseUpdates
|
||||
"missing_version"
|
||||
end
|
||||
|
||||
def new_features_endpoint
|
||||
"https://meta.discourse.org/new-features.json"
|
||||
end
|
||||
|
||||
def new_features_key
|
||||
"new_features"
|
||||
end
|
||||
|
Reference in New Issue
Block a user