diff options
Diffstat (limited to 'client.rb')
-rw-r--r-- | client.rb | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -45,6 +45,7 @@ post '/follow' do protected! params['id'] = actor params['mention'] if params['mention'] outbox 'Follow', params['id'], [params['id']] + 200 end post '/unfollow' do @@ -55,6 +56,7 @@ post '/unfollow' do activity ||= save_activity({ 'type' => 'Follow', 'actor' => ACTOR, 'object' => params['id'] }, OUTBOX) # recreate activity for old/deleted follows outbox 'Undo', activity, [params['id']] update_collection FOLLOWING, params['id'], true + 200 end post '/share' do # TODO @@ -72,6 +74,7 @@ end post '/login' do session['client'] = (OpenSSL::Digest::SHA256.base64digest(params['secret']) == File.read('.digest').chomp) + 200 end helpers do |