summaryrefslogtreecommitdiff
path: root/client.rb
diff options
context:
space:
mode:
Diffstat (limited to 'client.rb')
-rw-r--r--client.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/client.rb b/client.rb
index 5ef721b..c2995f5 100644
--- a/client.rb
+++ b/client.rb
@@ -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