Skip to content

Commit

Permalink
Fix UseSystemTextJsonForSerialization customization
Browse files Browse the repository at this point in the history
Closes #717
  • Loading branch information
drmohundro authored and jeremydmiller committed Feb 9, 2024
1 parent 61fccf7 commit dd8dee1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Wolverine/WolverineOptions.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public void UseSystemTextJsonForSerialization(Action<JsonSerializerOptions>? con
configuration?.Invoke(options);

var serializer = new SystemTextJsonSerializer(options);
_defaultSerializer ??= serializer;
_defaultSerializer = serializer;

_serializers[serializer.ContentType] = serializer;
}
Expand Down Expand Up @@ -120,4 +120,4 @@ public void AddSerializer(IMessageSerializer serializer)
{
_serializers[serializer.ContentType] = serializer;
}
}
}

0 comments on commit dd8dee1

Please sign in to comment.