Skip to content

Commit a16bc05

Browse files
committed
fix: 为BlankGetChannel类和方法添加Preserve属性
确保在Unity代码裁剪时相关成员不被意外移除
1 parent 41e8d8a commit a16bc05

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

Runtime/BlankGetChannel.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
/// sub_channel=test
3333
/// ]]></code>
3434
/// </remarks>
35+
[UnityEngine.Scripting.Preserve]
3536
public sealed class BlankGetChannel
3637
{
3738
#if UNITY_IOS || UNITY_TVOS || UNITY_VISIONOS
@@ -86,6 +87,7 @@ public sealed class BlankGetChannel
8687
/// string subChannel = BlankGetChannel.GetChannelName("sub_channel", "unknown");
8788
/// ]]></code>
8889
/// </example>
90+
[UnityEngine.Scripting.Preserve]
8991
public static string GetChannelName(string channelKey = "channel", string defaultValue = "default")
9092
{
9193
if (ChannelCache.TryGetValue(channelKey, out var value))

0 commit comments

Comments
 (0)