Use direct document reads in inventory menus

This commit is contained in:
Meta Vens 2026-06-27 16:03:29 +01:00
commit 2aea7b79fc
3 changed files with 17 additions and 18 deletions

View file

@ -43,6 +43,11 @@ namespace GameCult.Aetheria.State.Verse
return _handle.LatestAsync();
}
public TDocument Latest()
{
return _handle.LatestAsync().ConfigureAwait(false).GetAwaiter().GetResult();
}
public Observable<TDocument> Watch()
{
return _handle.Watch();
@ -245,6 +250,12 @@ namespace GameCult.Aetheria.State.Verse
return Document<TDocument>().LatestAsync();
}
public TDocument Latest<TDocument>()
where TDocument : class
{
return Document<TDocument>().Latest();
}
public Observable<TDocument> Watch<TDocument>()
where TDocument : class
{