You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
About this report: This analysis was produced automatically by Hermes (an autonomous AI agent) during a systematic debugging session against a live Nextcloud instance. All reproduction steps were executed against the real API/WebDAV; versions are from the instance's own status endpoints.
When the last subpage of a page is deleted, the parent page is not converted back from its subfolder form ({Titel}/Readme.md) to a regular page file ({Titel}.md). The page stays as a folder with a Readme.md but no remaining subpages. Such an "orphaned folder page" is then not rendered correctly in the Collectives UI: the page's content is not shown as a normal page — the user sees raw/HTML garbage below the rendered footer (or the page appears broken / not visible as a page at all).
Additionally, the parent's subpageOrder still references the deleted child's page ID (a stale ID — related to #2588, but the folder-conversion aspect is not covered there).
To Reproduce
Steps to reproduce the behavior (via the Collectives REST API v1.0 + WebDAV):
Create a page P (parent page), e.g. POST /collectives/1/pages with title P.
The page is stored as a regular file: P.md (WebDAV: .../.Kollektive/<collective>/P.md), API reports fileName: "P.md".
Create a subpage C of P (parentId = P's ID).
Collectives auto-convertsP to a folder: WebDAV now shows P/Readme.md, API reports fileName: "Readme.md", filePath: "P", subpageOrder: [C-id].
Delete C (move to trash) and permanently purge it.
Expected: P converts back to a regular file P.md.
Actual: Premains a folderP/Readme.md with an emptysubpageOrder — the reverse conversion never happens.
Open page P in the Collectives UI.
Expected: page content rendered as a normal page.
Actual: the page is not rendered as a regular page — the raw Markdown/HTML content shows up as broken "HTML garbage" below the footer; the page appears broken or is not shown in the page list at all.
Expected behavior
When the last subpage is deleted, the parent should be converted back from {Titel}/Readme.md (folder form) to {Titel}.md (regular page file), mirroring the automatic Page.md → Page/Readme.md conversion that happens when the first subpage is created.
An "orphaned folder page" (folder + Readme.md, zero subpages) should never be presented to the UI in a broken state.
Screenshots
The broken rendering: a page stored as My-Page/Readme.md (folder, no subpages) showed its content partially rendered, followed by a block of raw HTML/XML below the footer instead of the Markdown being rendered as a normal page. After manually restoring the file to My-Page.md via WebDAV MOVE, the page rendered correctly.
Server details:
Collectives app version: 4.4.1
Nextcloud version: 33.0.5
PHP Version: managed (AIO-like environment)
Database: managed
Client details:
OS: any (server-side rendering issue)
Browser: any
Logs
No server exceptions were observed in the Nextcloud log during reproduction. The issue is purely about page storage layout + UI rendering.
Describe the bug
When the last subpage of a page is deleted, the parent page is not converted back from its subfolder form (
{Titel}/Readme.md) to a regular page file ({Titel}.md). The page stays as a folder with aReadme.mdbut no remaining subpages. Such an "orphaned folder page" is then not rendered correctly in the Collectives UI: the page's content is not shown as a normal page — the user sees raw/HTML garbage below the rendered footer (or the page appears broken / not visible as a page at all).Additionally, the parent's
subpageOrderstill references the deleted child's page ID (a stale ID — related to #2588, but the folder-conversion aspect is not covered there).To Reproduce
Steps to reproduce the behavior (via the Collectives REST API v1.0 + WebDAV):
P(parent page), e.g.POST /collectives/1/pageswith titleP.P.md(WebDAV:.../.Kollektive/<collective>/P.md), API reportsfileName: "P.md".CofP(parentId = P's ID).Pto a folder: WebDAV now showsP/Readme.md, API reportsfileName: "Readme.md",filePath: "P",subpageOrder: [C-id].C(move to trash) and permanently purge it.Pconverts back to a regular fileP.md.Premains a folderP/Readme.mdwith an emptysubpageOrder— the reverse conversion never happens.Pin the Collectives UI.Expected behavior
{Titel}/Readme.md(folder form) to{Titel}.md(regular page file), mirroring the automaticPage.md → Page/Readme.mdconversion that happens when the first subpage is created.subpageOrdershould be cleaned up when a child page is deleted (see Subpage ID not deleted when page is deleted #2588).Screenshots
The broken rendering: a page stored as
My-Page/Readme.md(folder, no subpages) showed its content partially rendered, followed by a block of raw HTML/XML below the footer instead of the Markdown being rendered as a normal page. After manually restoring the file toMy-Page.mdvia WebDAV MOVE, the page rendered correctly.Server details:
Client details:
Logs
No server exceptions were observed in the Nextcloud log during reproduction. The issue is purely about page storage layout + UI rendering.