mirror of
https://github.com/ppy/osu.git
synced 2025-02-15 10:22:56 +08:00
Add signalr json type handling specification
This commit is contained in:
parent
4cf2c6188d
commit
1cd967b351
@ -150,7 +150,16 @@ namespace osu.Game.Online
|
||||
{
|
||||
// eventually we will precompile resolvers for messagepack, but this isn't working currently
|
||||
// see https://github.com/neuecc/MessagePack-CSharp/issues/780#issuecomment-768794308.
|
||||
builder.AddNewtonsoftJsonProtocol(options => { options.PayloadSerializerSettings.ReferenceLoopHandling = ReferenceLoopHandling.Ignore; });
|
||||
builder.AddNewtonsoftJsonProtocol(options =>
|
||||
{
|
||||
options.PayloadSerializerSettings.ReferenceLoopHandling = ReferenceLoopHandling.Ignore;
|
||||
options.PayloadSerializerSettings = new JsonSerializerSettings
|
||||
{
|
||||
// TODO: This should only be required to be `TypeNameHandling.Auto`.
|
||||
// See usage in osu-server-spectator for further documentation as to why this is required.
|
||||
TypeNameHandling = TypeNameHandling.All
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
var newConnection = builder.Build();
|
||||
|
Loading…
Reference in New Issue
Block a user