Fix the layer type test in LayerEditor component

`LayerSourceLayerBlock` was always included
This commit is contained in:
Frederic Junod 2019-10-16 15:34:24 +02:00
parent 95e205943a
commit 26de95a263

View file

@ -141,7 +141,7 @@ export default class LayerEditor extends React.Component {
onChange={v => this.changeProperty(null, 'source', v)}
/>
}
{['background', 'raster', 'hillshade', 'heatmap'].indexOf(this.state.type) < 0 &&
{['background', 'raster', 'hillshade', 'heatmap'].indexOf(this.props.layer.type) < 0 &&
<LayerSourceLayerBlock
sourceLayerIds={sourceLayerIds}
value={this.props.layer['source-layer']}