From fd744cf67ac531b854b8a094bd238b7e88f8e3df Mon Sep 17 00:00:00 2001 From: codefactor-io Date: Sat, 23 Nov 2019 20:44:19 +0000 Subject: [PATCH] [CodeFactor] Apply fixes --- app/models/planting.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/models/planting.rb b/app/models/planting.rb index ff21f295a..a043c7eb7 100644 --- a/app/models/planting.rb +++ b/app/models/planting.rb @@ -104,6 +104,7 @@ class Planting < ApplicationRecord def nearby_same_crop return if location.empty? + # latitude, longitude = Geocoder.coordinates(location, params: { limit: 1 }) Planting.joins(:garden) .where(crop: crop)