Skip to content
Snippets Groups Projects
Commit 3d3c3345 authored by Romain Derie's avatar Romain Derie Committed by fw-bot
Browse files

[FIX] website: prevent traceback if xml homepage view has no page


The XML file homepage view record is not supposed to be deleted as it is used
to bootstrap newly created website.

If that view is deleted, everything's fine. But if that view's page is not
found (m2o link broken somehow), then the code would crash.

This would only appear if the user is playing in the backend in technical but
it seems to happen more than it should.

This commit will prevent the code to crash in such a case.

Step to reproduce:
1. Go to settings > technical > views (debug)
2. Find the xml homepage view (with xml_id)
3. Go to its website.page and break the m2o view_id
4. Try to create a new website, it will crash

opw-2081894

closes odoo/odoo#39148

X-original-commit: 1d4dd200
Signed-off-by: default avatarRomain Derie (rde) <rde@odoo.com>
parent 67df6b91
Branches
Tags
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment