Fix geocoding in Rails 4 🎉

Responsibility for geocoding has moved from the `gmaps4rails` gem using `acts_as_taggable`, to the `geocoding` gem using `geocoded_by`. We already use this in the Address model.
This commit is contained in:
Matt-Yorkley
2020-02-29 12:40:40 +01:00
parent ddebd47e32
commit 847a349a6b
2 changed files with 1 additions and 2 deletions

View File

@@ -17,8 +17,6 @@ class Enterprise < ActiveRecord::Base
self.inheritance_column = nil
# acts_as_gmappable process_geocoding: false
has_many :relationships_as_parent, class_name: 'EnterpriseRelationship',
foreign_key: 'parent_id',
dependent: :destroy

View File

@@ -1,6 +1,7 @@
# Google requires an API key with a billing account to use their API.
# The key is stored in config/application.yml.
Geocoder.configure(
lookup: :google,
use_https: true,
api_key: ENV.fetch('GOOGLE_MAPS_API_KEY', nil)
)