diff --git a/packages/geo/src/lib/layer/layer-legend/layer-legend.component.ts b/packages/geo/src/lib/layer/layer-legend/layer-legend.component.ts index e798b4d935..0771354700 100644 --- a/packages/geo/src/lib/layer/layer-legend/layer-legend.component.ts +++ b/packages/geo/src/lib/layer/layer-legend/layer-legend.component.ts @@ -100,7 +100,7 @@ export class LayerLegendComponent implements OnInit, OnDestroy { } else if (this.styles && this.styles.length > 1) { this.currentStyle = lastlLegend[0].currentStyle; } - if (typeof this.layer.options.legendOptions !== 'undefined' && !this.layer.options.legendOptions.display) { + if (typeof this.layer.options.legendOptions !== 'undefined' && this.layer.options.legendOptions.display === false) { lastlLegend = []; } else { lastlLegend = this.layer.dataSource.getLegend(this.currentStyle, this.view);