fix: use getThesis() instead of getThesisById() in share recap page

getThesisById() filters by is_published=1, but theses submitted
via share links are unpublished. The recap page after submission
was showing 'TFE introuvable' because it couldn't find the
just-created unpublished thesis.
This commit is contained in:
Pontoporeia
2026-07-10 11:56:27 +02:00
parent 28c0efe755
commit 1025d99601
+2 -2
View File
@@ -18,8 +18,8 @@ if ($thesisId <= 0) {
}
$db = Database::getInstance();
// Only published theses are visible via public recap (no slug-auth here).
$thesis = $db->getThesisById($thesisId);
// Share-link theses may be unpublished; use getThesis() without published filter.
$thesis = $db->getThesis($thesisId);
if (!$thesis) {
http_response_code(404);
die('TFE introuvable.');