Skip to content

Commit

Permalink
fix(layer): This suscribe was not referencing to named id (#113)
Browse files Browse the repository at this point in the history
* This suscribe was not referencing to named id

This suscribe was not using the named id as defined into the context.json

* lint error
  • Loading branch information
pelord authored and mbarbeau committed Dec 7, 2017
1 parent 3a0b8b3 commit 1e353fc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/lib/context/shared/layer-context.directive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ export class LayerContextDirective implements OnInit, OnDestroy {
this.dataSourceService
.createAsyncDataSource(dataSourceContext)
.subscribe(dataSource => {
this.getLayerParamVisibilityUrl(dataSource.id, layerContext);
this.getLayerParamVisibilityUrl(
dataSource.options['id'] ?
dataSource.options['id'] : dataSource.id , layerContext);
this.map.addLayer(
this.layerService.createLayer(dataSource, layerContext));
});
Expand Down

0 comments on commit 1e353fc

Please sign in to comment.