weibo: fix bad artist name suggestions in new artist form.

Fix the new artist form suggesting invalid Chinese tag names for Weibo
artists. Suggest `weibo_123456` instead as a placeholder.
This commit is contained in:
evazion
2022-08-26 01:18:54 -05:00
parent 4d009568fd
commit f7794de0b7
2 changed files with 5 additions and 4 deletions

View File

@@ -47,14 +47,14 @@ module Source
end
end
def profile_urls
[parsed_url.profile_url, parsed_referer&.profile_url].compact.uniq
end
def profile_url
"https://www.weibo.com/u/#{artist_id}" if artist_id.present?
end
def tag_name
"weibo_#{artist_id}" if artist_id.present?
end
def artist_name
api_response&.dig("user", "screen_name")
end

View File

@@ -120,6 +120,7 @@ module Sources
artist_name: "号布谷鸟",
artist_commentary_desc: "<a href=\"https://m.weibo.cn/search?containerid=231522type%3D1%26t%3D10%26q%3D%23%E5%BF%AB%E9%80%92%E7%BB%84%23&extparam=%23%E5%BF%AB%E9%80%92%E7%BB%84%23&luicode=20000061&lfid=4767694689143828\" data-hide=\"\"><span class=\"surl-text\">#快递组#</span></a> 摸了 ",
profile_url: "https://www.weibo.com/u/6582241007",
profile_urls: ["https://www.weibo.com/u/6582241007"],
tags: ["快递组"]
)
end