Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-133544

Race condition on opening a created web content containing a geolocation field ReferenceError: google is not defined at e.getGeoCoder (GoogleMapsGeocoder.es.js:31)

    Details

      Description

      Description: After creating a web content with a structure that contains a geolocation field, we get this error when opening again this web content (not always is happening, looks like a race condition)

      react_devtools_backend.js:2560 ReferenceError: google is not defined at e.getGeoCoder (GoogleMapsGeocoder.es.js:31) at new e (GoogleMapsGeocoder.es.js:31) at e._getGeocoder (MapBase.es.js:329) at e._initializeLocation (MapBase.es.js:453) at new O (MapBase.es.js:120) at new e (MapOpenStreetMap.es.js:35) at c (useGeolocation.es.js:138) at useGeolocation.es.js:150 at y (useGeolocation.es.js:64) at useGeolocation.es.js:149
      

      Steps to reproduce:
      1. Go to Content & Data > Structures > Create a new Structure > Add a geolocation field to it > Save the Structure
      2. Go to Content & Data > Web Content > Create a new Web Content using the structure created at step 1
      3. Fill in the location for the geolocation field and Publish
      4. Go out of the web content and try to open it again (for the first time the error should occur, if not occurs reload the page while you are on the home page and try to open the created web content again) 

      Actual: There is an error when opening a web content that contains a geolocation field

      Expected: There is no error when opening a web content that contains a geolocation field

      Note: Once the error occurs if you reload the page when you have opened the web content multiple times, it will work from the second or third time reloading.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              guilherme.vilarim Guilherme Vilarim
              Reporter:
              georgel.pop Georgel Vasile Pop
              Participants of an Issue:
              Recent user:
              Sophia Zhang
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                21 weeks, 1 day ago

                  Packages

                  Version Package
                  7.4.2 CE GA3 DXP 7,4
                  7.4.13 DXP GA1
                  Master