FIX: visual regression for new features (#29359)

Bug introduced in this PR https://github.com/discourse/discourse/pull/29244

When the experiment toggle button was introduced, new features did not look right when the toggle button was not available.

In addition, the plugin name can be an empty string. In that case, information about new features should be displayed.
This commit is contained in:
Krzysztof Kotlarek
2024-10-23 16:16:19 +11:00
committed by GitHub
parent 11b62847e7
commit cd077ef93b
4 changed files with 17 additions and 10 deletions

View File

@ -165,7 +165,7 @@ module DiscourseUpdates
Discourse.has_needed_version?(current_version, item["discourse_version"])
valid_plugin_name =
item["plugin_name"].nil? || Discourse.plugins_by_name[item["plugin_name"]].present?
item["plugin_name"].blank? || Discourse.plugins_by_name[item["plugin_name"]].present?
valid_version && valid_plugin_name
rescue StandardError