Back to not using region names in geocoding, it seems to disturb OSM... :(
This commit is contained in:
parent
7c8285c149
commit
f47c5e8a12
@ -97,7 +97,9 @@ class Event < ActiveRecord::Base
|
||||
end
|
||||
|
||||
def full_address
|
||||
[address, city, region.try(:name)].compact.join ', '
|
||||
# Region seems to disturb openstreetmap :(
|
||||
# [address, city, region.try(:name)].compact.join ', '
|
||||
[address, city].compact.join ', '
|
||||
end
|
||||
|
||||
def hashtags
|
||||
|
@ -79,7 +79,9 @@ class Orga < ActiveRecord::Base
|
||||
end
|
||||
|
||||
def full_address
|
||||
[address, city, region.try(:name)].compact.join ', '
|
||||
# Region seems to disturb openstreetmap :(
|
||||
# [address, city, region.try(:name)].compact.join ', '
|
||||
[address, city].compact.join ', '
|
||||
end
|
||||
|
||||
def to_s
|
||||
|
@ -118,6 +118,7 @@ class EventTest < ActiveSupport::TestCase
|
||||
@event.city = 'world'
|
||||
# Region is no longer used for geocoding..;
|
||||
# @event.region.name = 'all'
|
||||
assert_equal 'hello, world, Alsace', @event.full_address
|
||||
# assert_equal 'hello, world, Alsace', @event.full_address
|
||||
assert_equal 'hello, world', @event.full_address
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user