Use a proven library to calculate distance

Also rounding distance at 2 decimals instead of round to 5
This commit is contained in:
Maddie Zhan
2020-08-20 10:22:47 +08:00
parent 01347b8514
commit b138d9b6bc
3 changed files with 40 additions and 42 deletions
+1
View File
@@ -20,6 +20,7 @@ require (
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/spf13/viper v1.7.1
github.com/umahmood/haversine v0.0.0-20151105152445-808ab04add26
go.etcd.io/bbolt v1.3.5
golang.org/x/image v0.0.0-20200801110659-972c09e46d76
golang.org/x/sys v0.0.0-20200819035508-9a32b3aa38f5 // indirect