From 7f3023df5be705436544b5724a6b83c2717aa0b8 Mon Sep 17 00:00:00 2001 From: pdp8 Date: Sat, 10 Aug 2024 00:29:02 +0200 Subject: improved outbox html, background sending --- server.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'server.rb') diff --git a/server.rb b/server.rb index d9983ef..ff1c73b 100644 --- a/server.rb +++ b/server.rb @@ -19,6 +19,7 @@ get '/' do end get '/outbox/:activity', provides: 'html' do + # outbox_html params['activity'] redirect "https://pdp8.info/social/#{params['activity']}.html" end @@ -137,8 +138,7 @@ helpers do def delete file = File.join(INBOX_DIR, @activity['object']['id'].sub('https://', '')) - # file, object = find_object(@activity['object']['id']) - FileUtils.rm(file) if file and File.exist? file # and @activity['actor'] == @activity['object']['attributedTo'] + FileUtils.rm_f(file) if file end def move -- cgit v1.2.3