g3w-suite / g3w-client

Map viewer addon for G3W-SUITE
https://g3w-suite.readthedocs.io/en/latest/g3wsuite_client.html
Mozilla Public License 2.0
21 stars 17 forks source link

Unhandled error when no print layout is set on the project (print setting is an empty array) #610

Closed volterra79 closed 7 months ago

volterra79 commented 7 months ago

Checklist

Subject of the issue

If we load a project without print layout, we get the following javascript error:

vendor.min.js:20897 TypeError: Cannot read properties of undefined (reading 'length')
    at a.noMaps (app.min.js:1:746142)
    at Nt.get (vendor.min.js:20897:17225)
    at Nt.evaluate (vendor.min.js:20897:18375)
    at a.noMaps (vendor.min.js:20897:20277)
    at i.render (app.min.js:1:748974)
    at e._render (vendor.min.js:20897:34654)
    at a.r (vendor.min.js:20897:67195)
    at Nt.get (vendor.min.js:20897:17225)
    at new Nt (vendor.min.js:20897:17143)
    at vendor.min.js:20897:67209


Steps to reproduce

  1. Load a project without print layouts

Environment

Link to your project

No response

Additional info

No response