Images return full URI (excl. host)

This commit is contained in:
2024-07-28 01:58:16 +02:00
parent 215ed1bc7f
commit 93e5cebce0
5 changed files with 49 additions and 7 deletions
+2 -1
View File
@@ -8,6 +8,7 @@ use Exception;
use Khofmann\Models\User\User;
use JsonSerializable;
use Khofmann\ApiError\ApiError;
use Khofmann\Config\Config;
use Khofmann\Database\Database;
use PDO;
@@ -27,7 +28,7 @@ class Post implements JsonSerializable
$this->id = $id;
$this->user = $user;
$this->name = $name;
$this->image = $image;
$this->image = Config::getStoragePath() . $image;
$this->content = $content;
$this->postedAt = new DateTime($postedAt);
}