Fix using screenshot as link preview

This commit is contained in:
Jay Trees 2022-04-08 10:46:01 +02:00
parent d84d55e061
commit 32592a315f

View file

@ -199,7 +199,7 @@ class Page
$screenshot_filepath = ROOT . '/src/assets/img/screenshots/' . $this->name . '.png';
$screenshot_url = 'https://' . $_SERVER['HTTP_HOST'] . '/src/assets/img/screenshots/' . $this->name . '.png';
if (file_exists($screenshot)) {
if (file_exists($screenshot_filepath)) {
$this->link_preview = $screenshot_url;
}
}