Skip to content

Commit

Permalink
Fix #22624: Improperly added resultOffset to URLs sent to MapWithAI s…
Browse files Browse the repository at this point in the history
…ervers

Signed-off-by: Taylor Smock <tsmock@meta.com>
  • Loading branch information
tsmock committed Jan 3, 2023
1 parent 070e4fb commit f4c7761
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -110,17 +110,18 @@ protected String getRequestForBbox(double lon1, double lat1, double lon2, double
.replace("{xmax}", Double.toString(lon2)).replace("{ymax}", Double.toString(lat2))
+ (crop ? "&crop_bbox=" + DetectTaskingManagerUtils.getTaskingManagerBounds().toBBox().toStringCSV(",")
: "")
+ (this.info.getSourceType() == MapWithAIType.ESRI_FEATURE_SERVER ? "&resultOffset=" + this.start : "");
+ (this.info.getSourceType() == MapWithAIType.ESRI_FEATURE_SERVER && !this.info.isConflated()
? "&resultOffset=" + this.start
: "");
}

@Override
public DataSet parseOsm(ProgressMonitor progressMonitor) throws OsmTransferException {
long startTime = System.nanoTime();
try {
DataSet externalData = super.parseOsm(progressMonitor);
if ((this.info.getSourceType() != MapWithAIType.ESRI_FEATURE_SERVER || this.start == 0) // Don't call
// conflate code
// unnecessarily
// Don't call conflate code unnecessarily
if ((this.info.getSourceType() != MapWithAIType.ESRI_FEATURE_SERVER || this.start == 0)
&& Boolean.TRUE.equals(MapWithAIInfo.THIRD_PARTY_CONFLATE.get()) && !this.info.isConflated()
&& !MapWithAIConflationCategory.conflationUrlFor(this.info.getCategory()).isEmpty()) {
if (externalData.getDataSourceBounds().isEmpty()) {
Expand Down

0 comments on commit f4c7761

Please sign in to comment.