mirror of
https://github.com/OPSnet/Gazelle.git
synced 2026-09-29 04:13:19 -04:00
13 lines
297 B
PHP
13 lines
297 B
PHP
<?php
|
|
/** @phpstan-var \Gazelle\User $Viewer */
|
|
|
|
$post = (new Gazelle\Manager\ForumPost())->findById((int)($_GET['post'] ?? 0));
|
|
if (is_null($post)) {
|
|
error(404);
|
|
}
|
|
if (!$Viewer->readAccess($post->thread()->forum())) {
|
|
error(403);
|
|
}
|
|
header('Content-type: text/plain');
|
|
echo $post->body();
|