pref(ModComp):提高代码可读性

This commit is contained in:
薄奚梦灵
2025-04-11 20:25:30 +08:00
committed by GitHub
parent 16e09c792c
commit 8dc1148ebc
@@ -61,8 +61,8 @@
If SplitedLine.Count >= 2 Then
Entry.ChineseName = SplitedLine(1)
If Entry.ChineseName.Contains("*") Then '处理 *
Entry.ChineseName = Entry.ChineseName.Replace("*", " (" &
String.Join(" ", If(Entry.CurseForgeSlug, Entry.ModrinthSlug).Split("-").Select(Function(w) w.Substring(0, 1).ToUpper & w.Substring(1, w.Length - 1))) & ")")
Entry.ChineseName = Entry.ChineseName.Replace("*",
$"({If(Entry.CurseForgeSlug, Entry.ModrinthSlug).Replace("-"," ").Capitalize})"
End If
End If
_CompDatabase.Add(Entry)