X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/cc461b126d30bb7b654719dc18369266aeb5183e..02aa14ffea55ef5ed4c488588a37d27bbf60f95b:/app/views/api/users/_user.xml.builder?ds=sidebyside diff --git a/app/views/api/users/_user.xml.builder b/app/views/api/users/_user.xml.builder index 9092f2c96..9fb74826a 100644 --- a/app/views/api/users/_user.xml.builder +++ b/app/views/api/users/_user.xml.builder @@ -1,6 +1,6 @@ xml.tag! "user", :id => user.id, :display_name => user.display_name, - :account_created => user.creation_time.xmlschema do + :account_created => user.created_at.xmlschema do xml.tag! "description", user.description if user.description if current_user && current_user == user && can?(:details, User) xml.tag! "contributor-terms", :agreed => user.terms_agreed.present?, @@ -25,7 +25,7 @@ xml.tag! "user", :id => user.id, end end if current_user && current_user == user && can?(:details, User) - if user.home_lat && user.home_lon + if user.home_location? xml.tag! "home", :lat => user.home_lat, :lon => user.home_lon, :zoom => user.home_zoom @@ -40,5 +40,6 @@ xml.tag! "user", :id => user.id, :unread => user.new_messages.size xml.tag! "sent", :count => user.sent_messages.size end + xml.tag! "email", user.email if scope_enabled?(:read_email) end end