correct weirdness in how user location is set

This commit is contained in:
Scott Comer 2014-05-12 21:13:16 -07:00
parent 833d9c9c38
commit 79136d2127
1 changed files with 6 additions and 5 deletions

View File

@ -221,11 +221,11 @@ module JamRuby
end
def location= location_hash
unless location_hash.blank?
unless location_hash.nil?
self.city = location_hash[:city]
self.state = location_hash[:state]
self.country = location_hash[:country]
end if self.city.blank?
end
end
def musician?
@ -776,9 +776,10 @@ module JamRuby
end
user.admin = false
user.city = location[:city]
user.state = location[:state]
user.country = location[:country]
user.location = location
# user.city = location[:city]
# user.state = location[:state]
# user.country = location[:country]
user.birth_date = birth_date
if musician