Files
Umbraco-CMS/src/Umbraco.Core/Preview/NoopPreviewTokenGenerator.cs
Bjarke Berg 11e5257b56 V14: Untangle the preview functionality from the auth cookie (#16308)
* AB40660 - untangle the preview cookie from the auth cookie

* Clean up

* Allow anonymous to end preview sessions

* Some refinements

* update OpenApi.json

* Fix enter preview test

* correct tests to match new expectations of the preview cookie

* sync preview tests with correct expectations of access level

---------

Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
2024-05-17 16:06:26 +02:00

9 lines
326 B
C#

namespace Umbraco.Cms.Core.Preview;
public class NoopPreviewTokenGenerator : IPreviewTokenGenerator
{
public Task<Attempt<string?>> GenerateTokenAsync(Guid userKey) => Task.FromResult(Attempt.Fail(string.Empty));
public Task<Attempt<Guid?>> VerifyAsync(string token) => Task.FromResult(Attempt.Fail<Guid?>(null));
}