Merge pull request #978 from sgmap/fix-432
[Fix #432] Stop raising a useless exception in get_position
This commit is contained in:
commit
c8f3b69943
1 changed files with 6 additions and 1 deletions
|
@ -31,7 +31,12 @@ class Users::CarteController < UsersController
|
|||
end
|
||||
|
||||
def get_position
|
||||
begin
|
||||
etablissement = current_user_dossier.etablissement
|
||||
rescue ActiveRecord::RecordNotFound
|
||||
etablissement = nil
|
||||
end
|
||||
|
||||
point = Carto::Geocodeur.convert_adresse_to_point(etablissement.geo_adresse) unless etablissement.nil?
|
||||
|
||||
lon = '2.428462'
|
||||
|
|
Loading…
Reference in a new issue