Dedent this code with a continue.

This commit is contained in:
voussoir 2023-04-02 12:12:32 -07:00
parent 61169a56de
commit 1a18ac22e4

View file

@ -253,8 +253,10 @@ class TrackerService: Service()
// very inaccurate points so if those bail early we'd stay in sleep mode. // very inaccurate points so if those bail early we'd stay in sleep mode.
for ((index, homepoint) in trackbook.homepoints.withIndex()) for ((index, homepoint) in trackbook.homepoints.withIndex())
{ {
if (homepoint.location.distanceTo(location) < homepoint.radius) if (homepoint.location.distanceTo(location) > homepoint.radius)
{ {
continue
}
Log.i("VOUSSOIR", "Omitting due to homepoint ${index} ${homepoint.name}.") Log.i("VOUSSOIR", "Omitting due to homepoint ${index} ${homepoint.name}.")
if (index > 0) if (index > 0)
{ {
@ -279,7 +281,6 @@ class TrackerService: Service()
} }
return return
} }
}
if (arrived_at_home > 0) if (arrived_at_home > 0)
{ {
Log.i("VOUSSOIR", "Leaving home.") Log.i("VOUSSOIR", "Leaving home.")