Skip to content

Commit 0b79913

Browse files
committed
[ECO-4567] Refactored MsgPackHelper config, added comments for unity build
1 parent 69a0667 commit 0b79913

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

cake-build/tasks/build.cake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ Task("_Build_Ably_Unity_Dll")
129129
// Get Unity dependency licenses and embed them into primaryDll
130130
// MergeResources returns the path to the modified DLL (same as input, but ensures file handles are closed)
131131
var unityLicenseFile = licenseHelper.GetUnityDependencyLicenses();
132+
// You can use ILDASM or ILSpy to decode unity/Assets/Ably/Plugins/IO.Ably.dll and check THIRD_PARTY_LICENSES.txt
132133
var primaryDllWithResources = monoCecilHelper.MergeResources(primaryDll, new FilePath[] { unityLicenseFile });
133134

134135
var dllsToMerge = deps.GetUnityPackageDependencies(netStandard20BinPath);

src/IO.Ably.Shared/MsgPack/MsgPackHelper.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,12 @@ internal static class MsgPackHelper
2222
AblyGeneratedResolver.Instance, // 1. Check generated code first (Fastest/Specific)
2323
AblyResolver.Instance, // 2. Check manual custom resolvers
2424
BuiltinResolver.Instance, // 3. Check standard types (List, DateTime)
25-
DynamicGenericResolver.Instance, // Priority 4: Collections, arrays, tuples
26-
PrimitiveObjectResolver.Instance, // Priority 5: typeof(object) fields
25+
DynamicGenericResolver.Instance, // 4: Check Collections, arrays, tuples
26+
PrimitiveObjectResolver.Instance, // 5: Check typeof(object) fields
2727
};
2828

2929
private static readonly MessagePackSerializerOptions DefaultOptions = MessagePackSerializerOptions.Standard
30-
.WithResolver(CompositeResolver.Create(Resolvers))
31-
.WithSecurity(MessagePackSecurity.UntrustedData);
30+
.WithResolver(CompositeResolver.Create(Resolvers));
3231

3332
public static byte[] Serialise<T>(T obj, MessagePackSerializerOptions options = null)
3433
{

0 commit comments

Comments
 (0)