Skip to content

Conversation

@juliusknorr
Copy link
Member

@juliusknorr juliusknorr commented Apr 30, 2024

Proper fix replacing #45031

When creating a file from a template we trigger a file action. This has a dependency on the file element $el that is used by some apps in <27 to get certain file attributes. Now while we wait for the file to be added to the file list, it might not be rendered if it is added at the end of the list outside the visible view.

This PR addresses it by adding a fallback to return the rendered row in case we could not find the element in the DOM.

Onlyoffice is one example using this https://github.com/ONLYOFFICE/onlyoffice-nextcloud/blob/master/src/main.js#L212 but there are potentially others out there as well.

Steps to reproduce:

  • Setup onlyoffice
  • Have a directory that has lots of files
  • Create a new file Called "Z.docx" so it is put at the very end of the file list from a template

Error before the change

Screenshot 2024-04-30 at 14 32 47

@juliusknorr juliusknorr requested review from a team, emoral435, nfebe and sorbaugh and removed request for a team April 30, 2024 12:30
@juliusknorr juliusknorr added bug 3. to review Waiting for reviews labels Apr 30, 2024
@juliusknorr juliusknorr added this to the Nextcloud 27.1.10 milestone Apr 30, 2024
@juliusknorr juliusknorr force-pushed the fix/get-row-outside branch from d59567d to 137b5a1 Compare May 13, 2024 13:19
@juliusknorr juliusknorr requested review from a team, max-nextcloud, sorbaugh, susnux and szaimen and removed request for a team, emoral435 and sorbaugh May 14, 2024 09:05
@szaimen szaimen removed their request for review May 14, 2024 09:24
@skjnldsv skjnldsv mentioned this pull request May 15, 2024
15 tasks
@skjnldsv skjnldsv mentioned this pull request May 22, 2024
10 tasks
@Altahrim Altahrim mentioned this pull request May 29, 2024
1 task
@susnux susnux merged commit 0f57633 into stable27 May 30, 2024
@susnux susnux deleted the fix/get-row-outside branch May 30, 2024 08:22
@blizzz blizzz mentioned this pull request Jun 11, 2024
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants