diff --git a/base_rest/__manifest__.py b/base_rest/__manifest__.py index 0026fa129..9025bf563 100644 --- a/base_rest/__manifest__.py +++ b/base_rest/__manifest__.py @@ -6,7 +6,7 @@ "summary": """ Develop your own high level REST APIs for Odoo thanks to this addon. """, - "version": "18.0.1.1.3", + "version": "18.0.1.1.4", "development_status": "Beta", "license": "LGPL-3", "author": "ACSONE SA/NV, Odoo Community Association (OCA)", diff --git a/base_rest/static/src/js/components/swagger_ui.js b/base_rest/static/src/js/components/swagger_ui.js index a63d1ed8a..4d7c80233 100644 --- a/base_rest/static/src/js/components/swagger_ui.js +++ b/base_rest/static/src/js/components/swagger_ui.js @@ -62,6 +62,9 @@ class SwaggerUI extends Component { whenReady(() => { const swaggerUiEl = document.getElementById("swagger-ui"); + if (!swaggerUiEl) { + return; + } const settings = JSON.parse(swaggerUiEl.getAttribute("data-settings") || "{}"); mount(SwaggerUI, swaggerUiEl, {props: {settings: settings}}); });