lint: remove unused code across api, comms, h3utils, html, middleware, minio, platform, rmo

Deleted files: api/compliance.go, api/debug.go, rmo/compliance.go, rmo/email.go,
rmo/mock.go, platform/publicreport/address.go

Removed unused functions/types from: api/api.go, api/configuration.go, api/district.go,
api/publicreport.go, api/sudo.go, api/types.go, comms/text/twilio.go,
comms/text/voipms.go, h3utils/h3.go, html/embed.go, html/form.go,
middleware/terminal.go, minio/client.go, platform/csv/csv.go,
platform/csv/flyover.go, platform/file/base.go, platform/file/upload.go,
platform/geocode/address.go, platform/types/service_request.go
This commit is contained in:
Eli Ribble 2026-05-09 14:47:56 +00:00
parent d74c24339e
commit 53a3f9816a
25 changed files with 6 additions and 975 deletions

View file

@ -37,23 +37,6 @@ func H3ToGeoJSON(indexes []h3.Cell) (interface{}, error) {
return featureCollection.JSON(), nil
}
// Given a cell at a smaller resolution remap it to the larger resolution
func scaleCell(cell h3.Cell, resolution int) (h3.Cell, error) {
r := cell.Resolution()
if r == resolution {
return cell, nil
}
latLong, err := cell.LatLng()
if err != nil {
return 0, fmt.Errorf("Failed to get latlng: %w", err)
}
scaled, err := h3.LatLngToCell(latLong, resolution)
if err != nil {
return 0, fmt.Errorf("Failed to create latlng: %w", err)
}
return scaled, nil
}
func GetCell(x, y float64, resolution int) (h3.Cell, error) {
latLng := h3.NewLatLng(y, x)
return h3.LatLngToCell(latLng, resolution)