Skip to content

Commit

Permalink
Do not include a BoundingBox tag in WMS responses, when it is null
Browse files Browse the repository at this point in the history
Update expected test results accordingly
  • Loading branch information
strk committed Oct 6, 2023
1 parent beb28f6 commit dc5d079
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion src/server/services/wms/qgswmsrenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1655,7 +1655,7 @@ namespace QgsWms
}
}

if ( featuresRect )
if ( featuresRect && ! featuresRect->isNull() )
{
if ( infoFormat == QgsWmsParameters::Format::GML )
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ Content-Type: text/xml; charset=utf-8

<?xml version="1.0" encoding="UTF-8"?>
<GetFeatureInfoResponse>
<BoundingBox maxy="0" maxx="0" miny="0" CRS="EPSG:3857" minx="0"/>
<Layer name="json">
<Feature id="2">
<Attribute value="2" name="pk"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ Content-Type: text/xml; charset=utf-8

<?xml version="1.0" encoding="UTF-8"?>
<GetFeatureInfoResponse>
<BoundingBox maxy="0" maxx="0" miny="0" CRS="EPSG:3857" minx="0"/>
<Layer name="json">
<Feature id="1">
<Attribute value="1" name="pk"/>
Expand Down

0 comments on commit dc5d079

Please sign in to comment.