Skip to content

Commit

Permalink
Consider case where id is layer name
Browse files Browse the repository at this point in the history
  • Loading branch information
mhugent committed Jan 5, 2019
1 parent e7c0f36 commit 9ed7b0d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/server/services/wms/qgswmsgetcapabilities.cpp
Expand Up @@ -690,7 +690,11 @@ namespace QgsWms
if ( cLayer )
{
QString layerName = cLayer->shortName();
if ( layerName.isEmpty() )
if ( QgsServerProjectUtils::wmsUseLayerIds( *project ) )
{
layerName = cLayer->id();
}
else if ( layerName.isEmpty() )
{
layerName = cLayer->name();
}
Expand Down

0 comments on commit 9ed7b0d

Please sign in to comment.