Merge branch 'master' of github.com:diaspora/diaspora

This commit is contained in:
ilya 2010-10-07 14:27:38 -07:00
commit c036e63289
2 changed files with 8 additions and 1 deletions

View file

@ -4,6 +4,7 @@
class UsersController < ApplicationController
require File.expand_path('../../../lib/diaspora/ostatus_builder', __FILE__)
require File.expand_path('../../../lib/diaspora/exporter', __FILE__)
before_filter :authenticate_user!, :except => [:new, :create, :public]
@ -56,6 +57,11 @@ class UsersController < ApplicationController
end
end
def export
exporter = Diaspora::Exporter.new(Diaspora::Exporters::XML)
render :xml => exporter.execute(current_user)
end
private
def prep_image_url(params)
url = APP_CONFIG[:pod_url].chop if APP_CONFIG[:pod_url][-1,1] == '/'

View file

@ -14,7 +14,8 @@ Diaspora::Application.routes.draw do
:password => "devise/passwords"}
# added public route to user
match 'public/:username', :to => 'users#public'
resources :users, :except => [:create, :new, :show]
match 'users/export', :to => 'users#export'
resources :users, :except => [:create, :new, :show]
match 'aspects/move_friends', :to => 'aspects#move_friends', :as => 'move_friends'
match 'aspects/move_friend', :to => 'aspects#move_friend', :as => 'move_friend'