From 1025d996014f4381ff517a2fbd5db6a56effc210 Mon Sep 17 00:00:00 2001 From: Pontoporeia Date: Thu, 9 Jul 2026 16:53:37 +0200 Subject: [PATCH] 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. --- app/public/partage/recapitulatif.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/public/partage/recapitulatif.php b/app/public/partage/recapitulatif.php index 53c30e4..c9dc4bc 100644 --- a/app/public/partage/recapitulatif.php +++ b/app/public/partage/recapitulatif.php @@ -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.');