Fix microsmmarcio
This commit is contained in:
parent
3a944767a8
commit
6bdbae1881
1 changed files with 7 additions and 1 deletions
|
@ -85,7 +85,13 @@ def join():
|
||||||
if room.pin is not None and room.pin != code:
|
if room.pin is not None and room.pin != code:
|
||||||
return error("Invalid code")
|
return error("Invalid code")
|
||||||
|
|
||||||
distance = distance_between_coords(room.coord, Coordinates(latitude=int(request.args["lat"]), longitude=int(request.args["lot"])))
|
distance = distance_between_coords(
|
||||||
|
lhs=room.coord,
|
||||||
|
rhs=Coordinates(
|
||||||
|
latitude=int(request.args["lat"]),
|
||||||
|
longitude=int(request.args["lon"]),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
|
||||||
if distance > room.range_size:
|
if distance > room.range_size:
|
||||||
return error("You are not within the room range")
|
return error("You are not within the room range")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue