<ul><li><strong>BUG FIX (HIGH)</strong> — <code>inc_legal_docs_manager.php</code>: Initialized <code>$categories = []</code> before conditional block; previously undefined variable caused PHP Warning and fatal foreach() on null when no legal docs existed</li><li><strong>BUG FIX (HIGH)</strong> — <code>js/custom_js.php</code>: Removed hardcoded <code>https://</code> from jsPDF CDN URL; changed to protocol-relative <code>//cdnjs.cloudflare.com</code> to prevent mixed-content failure on HTTP sites</li><li><strong>BUG FIX (MEDIUM)</strong> — <code>js/custom_js.php</code>: Added <code>isset()</code> guard on <code>$_GET['docs']</code> with <code>intval()</code> cast; previously caused PHP Notice on list page (no docs param)</li><li><strong>SPEED FIX (HIGH)</strong> — <code>page/legal_docs_list.php</code>: Eliminated N+1 query pattern — was executing one <code>domain_tblnm_legal_docs_signed</code> DB query per doc card in render loop; replaced with single pre-fetch bulk query before loop using lookup array</li><li><strong>SPEED FIX (HIGH)</strong> — Added missing index <code>idx_signByID</code> on <code>domain_tblnm_legal_docs_signed.signByID</code>; EXPLAIN changed from type:ALL (full scan, 48 rows) to type:ref (index lookup, 1 row)</li><li><strong>VALIDATION</strong> — 0 PHP errors, 0 JS console errors, 0 network failures before and after; UBOLD4 v4 layout confirmed intact; doc list, detail page, signed badge display, Export as PDF button all verified working</li></ul>