Skip to content
This repository has been archived by the owner on Nov 30, 2018. It is now read-only.

MultiPolygon will not render with lodash 4.x #1822

Open
sime opened this issue Apr 22, 2016 · 1 comment
Open

MultiPolygon will not render with lodash 4.x #1822

sime opened this issue Apr 22, 2016 · 1 comment
Labels

Comments

@sime
Copy link
Contributor

sime commented Apr 22, 2016

Trying to find the Polygon (within a MultiPolygon) with the most points fails with lodash 4.x.

error within chunking iterator: TypeError: Cannot read property 'max' of undefined

http://plnkr.co/edit/fugjhdeVZ10IRcgVj0td?p=preview

_.forEach does not accept a 3rd parameter as it is implemented here:

_.forEach(path.coordinates, (polygon, index) ->
if polygon[0].length > this.max
this.max = polygon[0].length
this.index = index
, trackMaxVertices)

I'm assuming lodash v4 is a hard dependency.

Update: Seems to happen with all 4.x version.s

@sime sime changed the title MultiPolygon will not render with lodash 4.11.2 MultiPolygon will not render with lodash 4.x Apr 22, 2016
@onlywei
Copy link

onlywei commented May 26, 2016

Could this be the culprit?

@clonedModel = _.clone @model, true if @isScopeModel

_.clone() no longer accepts a second argument for "isDeep" in Lodash 4.x.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants