Skip to content

Conversation

@LinneyS
Copy link

@LinneyS LinneyS commented Feb 6, 2023

Hi all
There are reports from users about ONLYOFFICE editors not working properly with opening after restoring a version. The problem repeats only in the group folder. Related to skipping the restore hook.

@juliushaertl
Please see the suggestion for a fix.

Signed-off-by: Sergey Linnik [email protected]

$targetMount->getStorage()->copyFromStorage($versionMount->getStorage(), $versionInternalPath, $targetInternalPath);
$versionMount->getStorage()->getCache()->copyFromCache($targetCache, $versionCache->get($versionInternalPath), $targetMount->getSourcePath() . '/' . $targetInternalPath);

\OC_Hook::emit('\OCP\Versions', 'rollback', [
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@icewind1991 I'd be curious if that should rather be emitted in the server after the backend method was called?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pushed a generic solution to nextcloud/server#36690

@solracsf
Copy link
Member

solracsf commented May 1, 2023

As nextcloud/server#36690 has been merged can this be closed?

@AndyXheli
Copy link

@LinneyS I have tested it on my Nextcloud 26 server running onlyoffice and it seems to fix the issue.

@solracsf solracsf closed this May 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants