diff --git a/src/GameCult.Mesh/CultMesh.cs b/src/GameCult.Mesh/CultMesh.cs index e37b07b1..4ec7940f 100644 --- a/src/GameCult.Mesh/CultMesh.cs +++ b/src/GameCult.Mesh/CultMesh.cs @@ -3315,9 +3315,16 @@ namespace GameCult.Mesh private static TDocument ReadRequired(CultCache cache, CultRecordKey key) where TDocument : class { - return cache.Get(key) - ?? throw new KeyNotFoundException( - $"CultMesh document '{key.Value}' was not found as {typeof(TDocument).FullName}."); + var document = cache.Get(key); + if (document != null) + return document; + + var untyped = cache.Get(key); + if (untyped != null && IsSameCultDocumentSchema(untyped.GetType())) + return ConvertUntypedDocument(untyped); + + throw new KeyNotFoundException( + $"CultMesh document '{key.Value}' was not found as {typeof(TDocument).FullName}."); } private static async Task ReadRequiredAsync(