mirror of
https://github.com/discourse/discourse.git
synced 2024-12-21 15:24:14 +08:00
e708c99e12
At the top of the theme show page we have a link to the theme About and License, which are supposed to be URLs. However some themes have left placeholder text in these metadata fields, which leads to a wonky experience. Instead, we can just not serialize these fields if they are not valid URLs, then they will not show as links in the UI.
11 lines
273 B
Ruby
11 lines
273 B
Ruby
# frozen_string_literal: true
|
|
|
|
Fabricator(:theme) do
|
|
name { sequence(:name) { |i| "Cool theme #{i + 1}" } }
|
|
user
|
|
end
|
|
|
|
Fabricator(:remote_theme) { remote_url { "https://github.com/org/testtheme.git" } }
|
|
|
|
Fabricator(:theme_with_remote_url, from: :theme) { remote_theme }
|