mapbox / simplespec-to-gl-style

Converts GeoJSON styled with simplestyle-spec to a GL Style
ISC License
31 stars 6 forks source link

don't use `value || 1` shortcut where `value` is potentially 0 #7

Closed jfirebaugh closed 8 years ago

jfirebaugh commented 8 years ago

*-width and *-opacity values can validly be 0. 0 is falsy, so a line like 'fill-opacity': feature.properties['fill-opacity'] || 1 will result in fill-opacity getting set to 1 when it should be 0.