-
Notifications
You must be signed in to change notification settings - Fork 284
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bbox #421
Bbox #421
Conversation
Signed-off-by: Holger Bruch <[email protected]> # Conflicts: # src/main/java/de/komoot/photon/query/PhotonRequestFactory.java
Signed-off-by: Holger Bruch <[email protected]> # Conflicts: # src/main/java/de/komoot/photon/query/PhotonRequestFactory.java
The previous test request was not consistent with the spec given in the documentation. I just swapped the latitude values.
if (minLat > 90.0 || minLat < -90.00 || maxLat > 90.0 || maxLat < -90.00) { | ||
throw new BadRequestException(400, INVALID_BBOX_ERROR_MESSAGE); | ||
} | ||
bbox = new Envelope(minLon, minLat, maxLon, maxLat); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a double error in here that happens to cancel itself out. bbox above is parsed as (minLon, maxLon, minLat, maxLat) while it should be (minLon, minLat, MaxLon, MaxLat). In the constructor for Envelope the exact reverse is true.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed code according to the documentation
Extension of #364 by @hbruch:
I basically just rebased origin/master as all previous remarks had already been fixed by hbruch