Fix: Undefined array key "content-warning"

This commit is contained in:
Michael 2024-05-18 11:15:47 +00:00
parent bda829665e
commit 058499cd92

View file

@ -238,6 +238,8 @@ function item_process(array $post, array $request, bool $preview, string $return
$post['api_source'] = false; $post['api_source'] = false;
$post['attach'] = ''; $post['attach'] = '';
$post['title'] = trim($request['title'] ?? ''); $post['title'] = trim($request['title'] ?? '');
$post['content-warning'] = trim($request['summary'] ?? '');
$post['sensitive'] = !empty($request['sensitive'] ?? false);
$post['body'] = $request['body'] ?? ''; $post['body'] = $request['body'] ?? '';
$post['location'] = trim($request['location'] ?? ''); $post['location'] = trim($request['location'] ?? '');
$post['coord'] = trim($request['coord'] ?? ''); $post['coord'] = trim($request['coord'] ?? '');