Skip to content

Commit

Permalink
Merge pull request #4865 from mhsdesign/bugfix/4728-fix-EditorContent…
Browse files Browse the repository at this point in the history
…StreamZookeeper

BUGFIX: 4728 fix editor content stream zookeeper
  • Loading branch information
mhsdesign authored Feb 2, 2024
2 parents 39fe053 + 77e56dc commit ab9f55b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Neos.Neos/Classes/Service/EditorContentStreamZookeeper.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
use Neos\ContentRepository\Core\Feature\WorkspaceCreation\Command\CreateWorkspace;
use Neos\ContentRepository\Core\Feature\WorkspaceRebase\Command\RebaseWorkspace;
use Neos\ContentRepository\Core\Projection\Workspace\Workspace;
use Neos\ContentRepository\Core\Projection\Workspace\WorkspaceStatus;
use Neos\ContentRepository\Core\SharedModel\User\UserId;
use Neos\ContentRepository\Core\SharedModel\Workspace\ContentStreamId;
use Neos\ContentRepository\Core\SharedModel\Workspace\WorkspaceDescription;
Expand Down Expand Up @@ -117,6 +118,11 @@ public function relayEditorAuthentication(Authentication\TokenInterface $token):
);
$workspace = $contentRepository->getWorkspaceFinder()->findOneByName($workspaceName);
if ($workspace !== null) {
if ($workspace->status !== WorkspaceStatus::OUTDATED) {
// the workspace is either okay or in conflict, which would prevent the editor from logging in
return;
}

CatchUpTriggerWithSynchronousOption::synchronously(fn() => $contentRepository->handle(
RebaseWorkspace::create(
$workspace->workspaceName,
Expand Down

0 comments on commit ab9f55b

Please sign in to comment.