question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot read property 'title' of undefined

See original GitHub issue

Hi!

As soon as I’m trying to draw a rectangle, i get this error:

TypeError: Cannot read property 'title' of undefined
at NewClass.getActions (http://localhost/Leaflet/Leaflet.draw/leaflet.draw.src.js:3081:43)
at NewClass._createActions (http://localhost/Leaflet/Leaflet.draw/leaflet.draw.src.js:2868:19)
at NewClass._showActionsToolbar (http://localhost/Leaflet/Leaflet.draw/leaflet.draw.src.js:2911:8)
at NewClass._handlerActivated (http://localhost/Leaflet/Leaflet.draw/leaflet.draw.src.js:2851:8)
at NewClass.fire (http://localhost/Leaflet/Leaflet/leaflet.src.js:588:11)
at NewClass.enable (http://localhost/Leaflet/Leaflet.draw/leaflet.draw.src.js:137:8)
at HTMLAnchorElement.handler (http://localhost/Leaflet/Leaflet/leaflet.src.js:9783:14)
at HTMLAnchorElement._super.bugsnag (http://localhost/BugSnag.js:165:42)

Using Firefox, but this also happens in (at least) Chrome.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
olemartinorgcommented, Nov 28, 2016

Ok, I fixed it! My mistake, of course. I had overwritten L.drawLocal with my own object, so that I could have translations for buttons/actions used in Leaflet.draw. I forgot to check that when upgrading to 0.4.0, so i didn’t notice that this new version brought with it the L.drawLocal.draw.toolbar.finish.title property.

0reactions
olemartinorgcommented, Nov 22, 2016

Huh, allright, I think I know what it is then. I have hacked on some code that adds a balloon/tooltip to every drawing upon creation, so that the user can edit those as well. I’ll have to get back to you with some example code that hopefully reproduces the problem. Sorry about my lack of digging (or thinking clearly), I submitted this at the end of my work day… 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot read property 'title' of undefined, but title is displayed
Error says that there is problem on line 10 in html. Without posting.html of your component it is hard to say where the...
Read more >
ERROR TypeError: Cannot read property title of undefined
HEY, SET YOUR LIKE THERE ! ... Your browser can't play this video. ... Solved: ERROR TypeError: Cannot read property title of undefined....
Read more >
autocomplete - error: Cannot read property 'title' of nul
Dear supporter, We are using autocomplete in our Angular 5 project. Unfortunately, we got the following error. null: ERROR null: TypeError: Cannot read...
Read more >
Cannot read property 'title' of undefined · Issue #9819 - GitHub
The code which you attached above seems fine. Take a look at at C:\Users\dexteroy\Desktop\LibraryApp\src\routes\adminRoutes.js:19:26 instead.
Read more >
Cannot read property 'title' of - Angular Error - CodeDocu.com
Typically, this occurs when data is still being fetched through a web api. Solved: ERROR TypeError: Cannot read property title of undefined.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found