Skip to content

Commit

Permalink
Remove unnecessary context from updateLatLong
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickbrophy committed Nov 25, 2024
1 parent 063e98b commit 156010f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions director/cache_ads.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ func (f filterType) String() string {
// 4. Set up utilities for collecting origin/health server file transfer test status
// 5. Return the updated ServerAd. The ServerAd passed in will not be modified
func recordAd(ctx context.Context, sAd server_structs.ServerAd, namespaceAds *[]server_structs.NamespaceAdV2) (updatedAd server_structs.ServerAd) {
if err := updateLatLong(ctx, &sAd); err != nil {
if err := updateLatLong(&sAd); err != nil {
switch err := err.(type) {
case GeoIPError:
labels := err.labels
Expand Down Expand Up @@ -246,7 +246,7 @@ func recordAd(ctx context.Context, sAd server_structs.ServerAd, namespaceAds *[]
return sAd
}

func updateLatLong(ctx context.Context, ad *server_structs.ServerAd) error {
func updateLatLong(ad *server_structs.ServerAd) error {
if ad == nil {
return errors.New("Cannot provide a nil ad to UpdateLatLong")
}
Expand Down

0 comments on commit 156010f

Please sign in to comment.