Updated 13 classes with new TryGetUmbracoContext

This commit is contained in:
Zeegaan
2021-08-11 11:06:55 +02:00
parent e9908e341f
commit 261b93f7be
13 changed files with 142 additions and 65 deletions

View File

@@ -142,7 +142,7 @@ namespace Umbraco.Cms.Infrastructure.PublishedCache
// elements cache (if we don't want to pollute the elements cache with short-lived
// data) depending on settings
// for members, always cache in the snapshot cache - never pollute elements cache
if (_publishedSnapshotAccessor.TryGetPublishedSnapshot(out publishedSnapshot))
if (!_publishedSnapshotAccessor.TryGetPublishedSnapshot(out publishedSnapshot))
{
throw new InvalidOperationException("Wasn't possible to a get a valid Snapshot");
}