Skip to content

bug: About-Us CMS pages have no file fallback; fresh DB returns 404 #754

Description

@yingliu-data

Bug Report

The About-Us family of CMS pages has no file fallback, contradicting the documented hybrid repository pattern, so a fresh database returns 404 for pages that ship bundled JSON.

service/CmsAboutUsService.java:47, 85, 104, 123, 142, 161 — every method throws ContentNotFoundException when the DB row is missing. The corresponding init-data files exist (teamPage.json, aboutUsPage.json, codeOfConductPage.json, celebrateHerPage.json, partnersPage.json, collaboratorPage.json) and PageRepository.getFallback is available and used elsewhere (CmsService/EventService/ProgrammeService/MentorshipPagesService), but is never called here.

Reproduction

Fresh database (no seeded pages) → GET /api/cms/v1/team, /about, /code-of-conduct, /celebrateHer, /partners, /collaborators all return 404, while /landingPage, /footer, /events, /programmes, and mentorship pages serve their bundled JSON.

Severity

Medium

Potential Risk

  • About-Us pages are broken on any environment without seeded content (fresh deploy, QA), inconsistent with every other page family.

Suggested Fix

  • Use the hybrid pattern in CmsAboutUsService: fall back to the bundled init-data JSON via PageRepository.getFallback when the DB row is absent.
  • Add tests asserting each About-Us endpoint serves the fallback on an empty DB.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingepic-about-usAll the "About Us" - navigation pagesjava/springbootTasks where is needed Java experience or Spring Boot Experience

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions