Skip to content

Added infinity exception to if statement inside Position object#416

Merged
cammace merged 3 commits intomasterfrom
cam-fix-infinity-log-issue
Apr 1, 2017
Merged

Added infinity exception to if statement inside Position object#416
cammace merged 3 commits intomasterfrom
cam-fix-infinity-log-issue

Conversation

@cammace
Copy link

@cammace cammace commented Mar 27, 2017

No description provided.

@mention-bot
Copy link

@cammace, thanks for your PR! By analyzing the history of the files in this pull request, we identified @zugaldia to be a potential reviewer.

this.altitude = altitude;

if (latitude < -90 || latitude > 90) {
if (latitude < -90 || latitude > 90 && latitude != Double.POSITIVE_INFINITY) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's do it a bit more readable with latitude != Double.POSITIVE_INFINITY && (latitude < -90 || latitude > 90)

@zugaldia
Copy link
Member

@cammace Note the () in my comment: latitude != Double.POSITIVE_INFINITY && (latitude < -90 || latitude > 90)

@cammace cammace merged commit edf66bd into master Apr 1, 2017
@cammace cammace deleted the cam-fix-infinity-log-issue branch April 1, 2017 16:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants