Include the home location in API user details response.
This commit is contained in:
parent
9861ca8001
commit
4b71f8aacd
1 changed files with 7 additions and 0 deletions
|
@ -58,6 +58,13 @@ class User < ActiveRecord::Base
|
|||
el1 = XML::Node.new 'user'
|
||||
el1['display_name'] = self.display_name.to_s
|
||||
el1['account_created'] = self.creation_time.xmlschema
|
||||
if self.home_lat and self.home_lon
|
||||
home = XML::Node.new 'home'
|
||||
home['lat'] = self.home_lat.to_s
|
||||
home['lon'] = self.home_lon.to_s
|
||||
home['zoom'] = self.home_zoom.to_s
|
||||
el1 << home
|
||||
end
|
||||
return el1
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue