Fix: ArchivModal kalkulator3d API response format

This commit is contained in:
2026-05-31 14:47:54 +02:00
parent 70fac26709
commit 0dcdfcbd52

View File

@@ -509,7 +509,8 @@ function ArchivModal({ calcId, onClose }) {
const mobile = window.innerWidth < 768;
useEffect(() => {
api('/tools/kalkulator3d').then(items => {
api('/tools/kalkulator3d').then(d => {
const items = d.own || d || [];
setItem(items.find(i => i.id === calcId) || null);
}).catch(() => {});
}, [calcId]);