Skip to content
This repository has been archived by the owner on Oct 17, 2022. It is now read-only.

TypeError: Cannot read property 'latitude' of null #37

Closed
ahmedmaazin opened this issue Apr 12, 2020 · 5 comments
Closed

TypeError: Cannot read property 'latitude' of null #37

ahmedmaazin opened this issue Apr 12, 2020 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@ahmedmaazin
Copy link

I'm getting the following error on the console with the new update of nova and the package. Tried setting a default value as well but still the same issue.

vendor.js?id=f9725df909a5af18907e:1 TypeError: Cannot read property 'latitude' of null

How I include the field within the Nova model is:

MapMarker::make("Location")->rules('required')->hideFromIndex()->help('Drag the map on to a location or try to search to get the location.'),

Notes:

  • This works on index, and update views.

version: "genealabs/nova-map-marker-field": "^0.1.16",
nova: v3.3.2

Thanks in advance :) Please have a look.

@mikebronner mikebronner self-assigned this Apr 12, 2020
@mikebronner mikebronner added the bug Something isn't working label Apr 12, 2020
@mikebronner
Copy link
Owner

I'll look into this over the coming week. Please feel free to submit a PR if you find the answer before me. :) Most likely something changed with the base field class in Nova 3.0.

@ahmedmaazin
Copy link
Author

Sure, I'll have a look as well. Thank you for checking it out.

@Hujairi
Copy link

Hujairi commented Apr 25, 2020

I'm getting a similar error,
firefox console shows:
TypeError: "this.field.value is null"
setInitialValue domain/nova-api/scripts/nova-map-marker-field:1
and
TypeError: "t.$refs.map is undefined"
mounted domain/nova-api/scripts/nova-map-marker-field:1

@Hujairi
Copy link

Hujairi commented Apr 27, 2020

I've updated nova to 3.4.1 and it's working now
and I also tried:
-npm install
-npm run dev
in the vendor folder, I don't know what actually solved it.

@mikebronner
Copy link
Owner

@Hujairi thanks for updating me on this. I will close this for now. If anyone is still getting these issues when using Nova 3.4.1+.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants