summaryrefslogtreecommitdiff
path: root/client.rb
diff options
context:
space:
mode:
authorpdp8 <pdp8@pdp8.info>2024-02-10 00:09:34 +0100
committerpdp8 <pdp8@pdp8.info>2024-02-10 00:09:34 +0100
commite4e4dedf8ca423e110787657799137444ca0f8fe (patch)
treed3bd95af4c58e76ca97b961f6e03e28376d8d6bb /client.rb
parent4586c63bd86fe3dad403086b15d5b74b6d67fc92 (diff)
outbox moved to website
Diffstat (limited to 'client.rb')
-rw-r--r--client.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/client.rb b/client.rb
index d19c6fc..891a1d8 100644
--- a/client.rb
+++ b/client.rb
@@ -28,6 +28,7 @@ post '/announce' do # TODO
to = ['https://www.w3.org/ns/activitystreams#Public', FOLLOWERS_URL]
to << params['attributedTo']
create_activity 'Announce', params['id'], to
+ outbox_html('announce')
200
end
@@ -41,6 +42,11 @@ post '/undo' do # TODO: generalize for announce
create_activity 'Undo', params['id'], activity['to']
FileUtils.rm(activity_file)
FileUtils.rm(object_file)
+ if activity_file.match 'create'
+ outbox_html('create')
+ elsif activity_file.match 'announce'
+ outbox_html('announce')
+ end
end
200
end